This is the mail archive of the gdb@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: info locals gives error


> From: Nick Roberts <nickrob@snap.net.nz>
> Date: Fri, 31 Mar 2006 18:38:03 +1200
> 
> I've just upgraded to Fedora Core 5 (kernel 2.6.15-1.2054_FC5) and with the
> program below I get errors which didn't occur before (Fedora Core 3).  This
> error might relate to Vladimir Prus's earlier report
> (http://sources.redhat.com/ml/gdb-patches/2006-03/msg00225.html) and
> value_print.
> 
> 
> /* -*- compile-command: "cc -g -o simple simple.c"; -*- */
> 
> main(int argc, char **argv) {
>   int i;
>   i = 1;
> }
> [...]
>   (gdb) b main
>   Breakpoint 1 at 0x8048354: file simple.c, line 3.
>   (gdb) r
>   Starting program: /home/nickrob/simple
>   Reading symbols from shared object read from target memory...done.
>   Loaded system supplied DSO at 0x80e000
>   
>   Breakpoint 1, main () at simple.c:3
>   3       main(int argc, char **argv) {
>   (gdb) info locals
>   argc = Cannot access memory at address 0x0

I cannot reproduce this with GDB 6.4 and GCC versions 3.3.5 and 4.0.0
on a Debian box.  I also tried GCC 3.4.2 and GDB 6.3 on a Windows box.
What I get in all of those cases is some arbitrary garbage, not
"cannot access".


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