Public bug reported:

Binary package hint: gdb

When debugging some code in gdb, the resulting stacktraces on segfaults
tend to be useless when the code that is segfaulting has no
debuginformation. In such a case, the _complete_ stack looks screwed. An
example should explain the situation.

The original stacktrace that I get for my application looks like this:

(gdb) bt
#0  0xb78f485e in ?? () from /usr/lib/libX11.so.6
#1  0x00000000 in ?? ()

Now, when I go and install libx11-6-dbg (which has debuginfo for
libX11.so.6) I get this:

(gdb) bt
#0  0xb793385e in GetDatabase (db=0x84e0af8, 
    str=0x84d1518 
"*Box.background:\t#efebe7\n*Box.foreground:\t#101010\n*Button.activeBackground:\t#ffffff\n*Button.activeForeground:\t#101010\n*Button.background:\t#efebe7\n*Button.foreground:\t#101010\n*Button.highlightBackgroun"...,
 filename=0x0, 
    doall=1) at ../../src/Xrm.c:1104
#1  0xb7934781 in XrmGetStringDatabase (
    data=0x84d1518 
"*Box.background:\t#efebe7\n*Box.foreground:\t#101010\n*Button.activeBackground:\t#ffffff\n*Button.activeForeground:\t#101010\n*Button.background:\t#efebe7\n*Button.foreground:\t#101010\n*Button.highlightBackgroun"...)
    at ../../src/Xrm.c:1566
#2  0xb7910cbc in XGetDefault (dpy=0x84ccdc8, prog=0xb79ed5b5 "Xcursor", 
    name=0xb79ed647 "core") at ../../src/GetDflt.c:173
#3  0xb79ea4dd in _XcursorGetDisplayInfo () from /usr/lib/libXcursor.so.1
#4  0xb79ea5dd in XcursorGetTheme () from /usr/lib/libXcursor.so.1
#5  0xb7a95b74 in gdk_x11_display_set_cursor_theme ()
   from /usr/lib/libgdk-x11-2.0.so.0
#6  0xb7d61a6f in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#7  0x084d40e8 in ?? ()
#8  0x084e6f60 in ?? ()
#9  0x00000018 in ?? ()
#10 0xb7ee51ff in ?? () from /usr/lib/libgtk-x11-2.0.so.0
#11 0xb700eff4 in ?? ()
#12 0x00000000 in ?? ()


Now I see one more library without debug information. When I install this too, 
I have a complete normal stacktrace, including my own application's code at the 
bottom.

This behaviour seems unnatural. GDB should show ?? only for stackframes
without debug info, but for the others it normally still shows the debug
information it has. The situation is especially bad when an application
crashes in a proprietary piece (like the nvidia driver) which has no
debug information at all.

** Affects: gdb (Ubuntu)
     Importance: Undecided
         Status: Unconfirmed

-- 
gdb screws stacktraces when no debuginfo is present
https://bugs.launchpad.net/bugs/111869
You received this bug notification because you are a member of Ubuntu
Bugs, which is the bug contact for Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to