This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Manipulating memory
On Tuesday 05 August 2008 21:03:38 Eran Ifrah wrote:
> Hi,
>
> I have read the GDB manual, and I could not find a way to manipulate a
> memory, for example: set values at given address. I only found a way
> to view it using '-data-read-memory' command,
> is this true or did I miss something?
I'd be glad if someone had a real solution for that task, too.
So far I used something along the lines of
call sprintf(address, "%d %s ..", token, ... )
to write something to target memory, but I am looking for an alternative
too, as this gets mis-parsed in some cases.
Maybe
restore filename [binary] bias start end
as described in section 8.16 of the manual would help, but that seems to
require the contents to be put in a file first. Not really convenient either...
Regards,
André