Backtrace Should Look Like

From Bluefish Wiki
Jump to navigation Jump to search
fender:~/cvsbluefish$ gdb src/bluefish
GNU gdb 5.3.90_2003-08-24-cvs-debian
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type \"show copying\" to see the conditions.
There is absolutely no warranty for GDB.  Type \"show warranty\" for details.
This GDB was configured as \"i386-linux\"...
(gdb) r
Starting program: /home/olivier/bluefish/cvs/bluefish-gtk2/src/bluefish
New Thread 16384 (LWP 3049)
new_pixmap, requested unknown type 199


Program received signal SIGSEGV, Segmentation fault.
Switching to Thread 16384 (LWP 3049)
doc''get''next_word (bfspell<code>0x0, itstart</code>0xbfffed10, itend=0xbfffecd0) at bfspell.c:58
58              if (bfspell->eo && bfspell->offset <code></code>-1) {
(gdb) bt
#0  doc''get''next_word (bfspell<code>0x0, itstart</code>0xbfffed10, itend=0xbfffecd0) at bfspell.c:58
#1  0x08059b29 in spell_run (bfspell=0x82c2a38) at bfspell.c:142
#2  0x08059e9b in spell''gui''ok''clicked''cb (widget<code>0x8364c88, bfspell</code>0x82c2a38) at bfspell.c:246
#3  0x403a4212 in g''cclosure''marshal''VOID''VOID () from /usr/lib/libgobject-2.0.so.0
#4  0x40393a92 in g''closure''invoke () from /usr/lib/libgobject-2.0.so.0
#5  0x403a3da6 in g''signal''emit''by''name () from /usr/lib/libgobject-2.0.so.0
#6  0x403a2ec2 in g''signal''emit_valist () from /usr/lib/libgobject-2.0.so.0
#7  0x403a30d6 in g''signal''emit () from /usr/lib/libgobject-2.0.so.0
#8  0x40070537 in gtk''button''clicked () from /usr/lib/libgtk-x11-2.0.so.0
#9  0x400714fb in ''gtk''button_paint () from /usr/lib/libgtk-x11-2.0.so.0
#10 0x403a4212 in g''cclosure''marshal''VOID''VOID () from /usr/lib/libgobject-2.0.so.0
#11 0x40393d44 in g''cclosure''new_swap () from /usr/lib/libgobject-2.0.so.0
#12 0x40393a92 in g''closure''invoke () from /usr/lib/libgobject-2.0.so.0
#13 0x403a36c4 in g''signal''emit''by''name () from /usr/lib/libgobject-2.0.so.0
#14 0x403a2ec2 in g''signal''emit_valist () from /usr/lib/libgobject-2.0.so.0
#15 0x403a30d6 in g''signal''emit () from /usr/lib/libgobject-2.0.so.0
#16 0x40070487 in gtk''button''released () from /usr/lib/libgtk-x11-2.0.so.0
#17 0x4007137b in ''gtk''button_paint () from /usr/lib/libgtk-x11-2.0.so.0
#18 0x400f8282 in ''gtk''marshal''BOOLEAN''BOXED () from /usr/lib/libgtk-x11-2.0.so.0
#19 0x40393d44 in g''cclosure''new_swap () from /usr/lib/libgobject-2.0.so.0
#20 0x40393a92 in g''closure''invoke () from /usr/lib/libgobject-2.0.so.0
#21 0x403a3895 in g''signal''emit''by''name () from /usr/lib/libgobject-2.0.so.0
#22 0x403a2ca3 in g''signal''emit_valist () from /usr/lib/libgobject-2.0.so.0
#23 0x403a30d6 in g''signal''emit () from /usr/lib/libgobject-2.0.so.0
#24 0x401d6c6b in gtk''widget''send_expose () from /usr/lib/libgtk-x11-2.0.so.0
#25 0x400f8057 in gtk''propagate''event () from /usr/lib/libgtk-x11-2.0.so.0
#26 0x400f6db6 in gtk''main''do_event () from /usr/lib/libgtk-x11-2.0.so.0
#27 0x402b0f85 in ''gdk''events_queue () from /usr/lib/libgdk-x11-2.0.so.0
#28 0x403e3086 in unblock_source () from /usr/lib/libglib-2.0.so.0
#29 0x403e4029 in g''main''context_dispatch () from /usr/lib/libglib-2.0.so.0
#30 0x403e4347 in g''main''context_dispatch () from /usr/lib/libglib-2.0.so.0
#31 0x403e49b0 in g''main''loop_run () from /usr/lib/libglib-2.0.so.0
#32 0x400f65df in gtk_main () from /usr/lib/libgtk-x11-2.0.so.0
#33 0x0805b66c in main (argc<code>1, argv</code>0xbffffc94) at bluefish.c:231
(gdb)

Obviously this is a fake backtrace, I created the bug just to show what would happen.

Note that you can see every function call made from bluefish or from any library, and note that you can see the line numbers where each call is made. This helps a lot during debugging.