Reputation: 1464
I am seeing value of the variable passed to a function is becoming null after returning from the function. The variable is pushed to the stack and while returning the same is pop. Do we have a way to find the culprit thread ? Can i protect the that stack location ? i did check the assembly and dont see any offset to rbp which may change stack ?
push %rbp
mov %rsp,%rbp
push %rbx
.....................
add $0x8,%rsp
pop %rbx
leaveq
Upvotes: 0
Views: 152
Reputation: 182885
Just debug the program normally. You're trying to make things much harder than they need to be.
Upvotes: 1
Reputation: 9171
I think the operating system should be protecting your process from any other process messing with it's memory. Are you certain you don't have memory corruption within your program? Do you have multiple threads? Those are more likely culprits than another rogue process.
Upvotes: 1