Re: gtk2 Segmentation faults



Kristian Peters <kristian peters korseby net> writes:

> Neil Bird <neil fnxweb com> wrote:
> >    Do a 'bt' command in gdb after the crash; that'll show you the 
> > current stack of procedure calls.
> 
> Program received signal SIGSEGV, Segmentation fault.
> gdk_window_get_geometry (window=0x0, x=0x0, y=0x0, width=0x4067ef5c, height=0x4067ef60, depth=0x0) at gdkwindow-x11.c:2147
> /misc/data/Projekte/gamp-0.0.6/gdkwindow-x11.c:2147:60427:beg:0x4027ff5c
> (gdb) bt
> #0  gdk_window_get_geometry (window=0x0, x=0x0, y=0x0, width=0x4067ef5c, height=0x4067ef60, depth=0x0) at gdkwindow-x11.c:2147
> #1  0x406684ba in gdk_input_common_init () from /usr/lib/libgdk-1.2.so.0
> #2  0x4066916d in gdk_input_init () from /usr/lib/libgdk-1.2.so.0
> #3  0x40654d3d in gdk_init_check () from /usr/lib/libgdk-1.2.so.0
> #4  0x40019fa1 in real_gdk_init_check () from /usr/lib/libgdkxft.so.0
> #5  0x40019048 in gdk_init_check () from /usr/lib/libgdkxft.so.0
> #6  0x400edaf6 in gtk_init_check (argc=0xbffff860, argv=0xbffff864) at gtkmain.c:588
> #7  0x400edecf in gtk_init (argc=0xbffff860, argv=0xbffff864) at gtkmain.c:779
> #8  0x08048758 in main (argc=1, argv=0xbffff8c4) at test.c:9
> #9  0x40403306 in __libc_start_main (main=0x8048730 <main>, argc=1, ubp_av=0xbffff8c4, init=0x8048578 <_init>, fini=0x80487e0 <_fini>, rtld_fini=0x4000d2dc <_dl_fini>, stack_end=0xbffff8bc) at ../sysdeps/generic/libc-start.c:129
> (gdb) 
> 
> Obviously there is a fault here. That should be NOT libgdk-1.2.so.0 but libgdk-x11-2.0.so.0 ! I suspect it is wrongly linked... But pkgconfig does the right thing:
> 
> $ pkg-config --cflags --libs gtk+-2.0 
>  -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/X11R6/include -I/usr/include/freetype2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangox-1.0 -lpangoxft-1.0 -lpango-1.0 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0
> 
> So what's going on here ?

You are using GtkXft. :-) Turn it off and things will work a lot better.

Regards,
                                        Owen




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]