Unable to change the values of $ebp and $eip
Daniel Jacobowitz
drow@false.org
Wed Apr 25 11:22:00 GMT 2007
On Wed, Apr 25, 2007 at 09:39:06AM +0000, Kalpana Ramamurthy wrote:
> Why does this happen ? Why am I not able to set/change values of $ebp and $eip
> in the macro after I switch to a non-zero frame (older frame) ? The macro works
> great when I start execution of it from frame 0.
When you're in an earlier thread, "$eip" refers to that thread's
return address. Which in turn refers to a location on the stack where
it is saved. You're talking to a core file, so GDB can not write to
memory.
Honestly, I'm surprised that it works from frame 0 either. I would
have expected writing to "registers" to fail.
--
Daniel Jacobowitz
CodeSourcery
More information about the Gdb
mailing list