This is the mail archive of the gdb@sources.redhat.com 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: newB: How to debug system lib


Russell Shaw <rjshaw@netspace.net.au> wrote:
> In gdb, list 'ungetc' (a gnu libc function) gives:
>
>    No line number information available for address 0x400af9a0 <ungetc>
>
> I cannot step into the function either.

Try this:

  (gdb) break main
  (gdb) run
  (gdb) disassemble ungetc
  (gdb) list ungetc

The "break main; run" will run your test program far enough to load
the shared library (glibc).  gdb will see the shared library after
it is loaded.

Hope this helps,

Michael Chastain


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