This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Doc]tracepoint: change *$esp@300 to *(unsigned char *)$esp@300


On Tuesday 24 August 2010 19:07:17, Michael Snyder wrote:
> I think the reason it doesn't work now is that it's typed as a void pointer.
> 
> (gdb) pt $esp
> type = void *
> 
> Probably it used to be typed as a char * or something.

Dereferencing void* used to "work" in agent expressions,
but since it is forbidden in normal expressions, 

 (gdb) p *$sp
 Attempt to dereference a generic pointer.

the agent expression code was fixed to behave the same:

2010-02-11  Pedro Alves  <pedro@codesourcery.com>

        * ax-gdb.c (gen_deref): Don't allow dereferencing void pointers.

Let's just fix the docs.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]