Web lists-archives.com

Re: gdk_flush: Segmentation fault




OK, I found how to fix the problem: I need to use the '-O1' gcc optimization flag instead of '-O2' when building libxcb.
Well, in fact, it is just a workaround and not a fix because I prefer the '-O2' optimization flag but unfortunately I can't use it for building libxcb.
Thanks to Ilya Lipnitskiy (lipnitsk) for this idea: https://bugs.archlinux.org/task/49560

On Thu, 31 Aug 2017 16:48:05 +0200
YuGiOhJCJ Mailing-List via gtk-list <gtk-list@xxxxxxxxx> wrote:

> Unfortunately, 25Assist is not an open-source program.
> So, I only have binaries and I can't rebuild it.
> However, I rebuilt gtk+2, libX11 and libxcb with the '-g' flag.
> Here is the new GDB backtrace containing more debugging symbols:
> ---
> $ gdb 25Assist
> GNU gdb (GDB) 7.11.1
> Copyright (C) 2016 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "x86_64-slackware-linux".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
> <http://www.gnu.org/software/gdb/documentation/>.
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from 25Assist...(no debugging symbols found)...done.
> (gdb) run
> Starting program: /opt/25assist-20151223/25Assist 
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib64/libthread_db.so.1".
> warning: File "/usr/lib/libstdc++.so.6.0.23-gdb.py" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
> To enable execution of this file add
> 	add-auto-load-safe-path /usr/lib/libstdc++.so.6.0.23-gdb.py
> line to your configuration file "/home/yugiohjcj/.gdbinit".
> To completely disable this security protection add
> 	set auto-load safe-path /
> line to your configuration file "/home/yugiohjcj/.gdbinit".
> For more information about this security protection see the
> "Auto-loading safe path" section in the GDB manual.  E.g., run from the shell:
> 	info "(gdb)Auto-loading safe path"
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0xf6f1d6e1 in xcb_writev (c=0x82cbd50, vector=0xffff9e0c, count=3, requests=73) at xcb_out.c:405
> 405	    c->out.request += requests;
> (gdb) bt
> #0  0xf6f1d6e1 in xcb_writev (c=0x82cbd50, vector=0xffff9e0c, count=3, requests=73) at xcb_out.c:405
> #1  0xf767f85e in _XSend (dpy=0x82cb400, data=0x0, size=0) at xcb_io.c:486
> #2  0xf767fe19 in _XReply (dpy=0x82cb400, rep=0xffff9ec4, extra=0, discard=1) at xcb_io.c:573
> #3  0xf767b943 in XSync (dpy=0x82cb400, discard=0) at Sync.c:44
> #4  0xf7a537b2 in IA__gdk_flush () at gdkevents-x11.c:2606
> #5  0xf7a23170 in alloc_scratch_image (image_info=<optimized out>) at gdkimage.c:527
> #6  _gdk_image_get_scratch (screen=0x82da0b8, width=160, height=23, depth=24, x=0xffff9fbc, y=0xffff9fc0) at gdkimage.c:592
> #7  0xf7a30fbe in gdk_draw_rgb_image_core (image_info=0x83f3bf8, drawable=drawable@entry=0x82c6c00, gc=gc@entry=0x82d8e80, x=0, y=0, width=160, height=23, 
>     buf=0x840bc48 "\371\371\371nnn\022\022\022", pixstride=3, rowstride=480, conv=0xf7a2f0a0 <gdk_rgb_convert_0888>, cmap=0x0, xdith=0, ydith=0) at gdkrgb.c:3327
> #8  0xf7a329e9 in IA__gdk_draw_rgb_image (drawable=0x82c6c00, gc=0x82d8e80, x=0, y=0, width=160, height=23, dith=GDK_RGB_DITHER_MAX, rgb_buf=0x840bc48 "\371\371\371nnn\022\022\022", 
>     rowstride=480) at gdkrgb.c:3393
> #9  0x0809d97e in ?? ()
> #10 0x081124a0 in ?? ()
> #11 0x081124d5 in ?? ()
> #12 0xf6252292 in ?? ()
> #13 0xf60cf138 in ?? ()
> #14 0xf60cf3a3 in ?? ()
> #15 0xf62d3f00 in ?? ()
> #16 0xf62ceb8b in ?? ()
> #17 0x0807077d in ?? ()
> #18 0x08070888 in ?? ()
> #19 0x08179267 in ?? ()
> #20 0xf6100128 in ?? ()
> #21 0x0816d65a in ?? ()
> #22 0x0816d64e in ?? ()
> #23 0x0816d75f in ?? ()
> #24 0xf668681b in ?? ()
> #25 0xf60b5308 in ?? ()
> #26 0xf60b53b4 in ?? ()
> #27 0xf6255333 in ?? ()
> #28 0xf60b5469 in ?? ()
> #29 0xf60b5024 in ?? ()
> #30 0x080d2592 in ?? ()
> #31 0x0816c1b1 in ?? ()
> #32 0xf72be4d3 in __libc_start_main () from /lib/libc.so.6
> #33 0x08052b21 in ?? ()
> (gdb) quit
> A debugging session is active.
> 
> 	Inferior 1 [process 18645] will be killed.
> 
> Quit anyway? (y or n) y
> ---
> 
> Can you see the reason of the problem now?
> 
> On Thu, 31 Aug 2017 07:02:48 -0700
> Link Dupont <link@xxxxxxxxxxx> wrote:
> 
> > On Thu, 2017-08-31 at 15:56 +0200, YuGiOhJCJ Mailing-List via gtk-list wrote:
> > > Reading symbols from 25Assist...(no debugging symbols found)...done.
> > 
> > Try rebuilding your program with debugging symbols. If you're using autotools,
> > return configure with --enable-debug. If you're simply building with gcc
> > directly, add the -g flag.
> > 
> > That hopefully will fill in a lot of the unknown functions.
> > 
> > ~link
> _______________________________________________
> gtk-list mailing list
> gtk-list@xxxxxxxxx
> https://mail.gnome.org/mailman/listinfo/gtk-list
_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
https://mail.gnome.org/mailman/listinfo/gtk-list