Crash on startup due to X Window System error (BadAlloc) on FreeBSD
I've recently updated my FreeBSD machines, running FreeBSD head, and on my laptop I'm now getting a strange xfwm4 crash on startup.
Strange thing this is not happening on other hardware, this machine has AMD graphics, other machines have nvidia or intel, maybe that's related.
This is the error I'm getting:
(xfwm4:2083): Gdk-ERROR **: 22:27:41.448: The program 'xfwm4' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadAlloc (insufficient resources for operation)'.
(Details: serial 1728 error_code 11 request_code 149 (unknown) minor_code 2)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
I've compiled xfwm4 with debug synbols and this is a backtrace:
(gdb) bt
#0 0x000000082ffacb2a in g_log_writer_default () at /usr/local/lib/libglib-2.0.so.0
#1 0x000000082ffac0b8 in g_log_structured_array () at /usr/local/lib/libglib-2.0.so.0
#2 0x000000082ffac91c in g_log_structured_standard () at /usr/local/lib/libglib-2.0.so.0
#3 0x000000082852f779 in () at /usr/local/lib/libgdk-3.so.0
#4 0x000000082853cd1c in () at /usr/local/lib/libgdk-3.so.0
#5 0x0000000832869ef7 in _XError () at /usr/local/lib/libX11.so.6
#6 0x0000000832866776 in () at /usr/local/lib/libX11.so.6
#7 0x000000083286607d in _XEventsQueued () at /usr/local/lib/libX11.so.6
#8 0x0000000832866ba7 in _XFlush () at /usr/local/lib/libX11.so.6
#9 0x0000000832867e53 in _XGetRequest () at /usr/local/lib/libX11.so.6
#10 0x0000000823715fdc in XFixesSelectCursorInput () at /usr/local/lib/libXfixes.so.3
#11 0x0000000000231951 in compositorManageScreen (screen_info=0x857234800) at compositor.c:5011
#12 0x000000000025522e in init_compositor_screen (screen_info=0x857234800) at main.c:495
#13 0x0000000000254851 in initialize (replace_wm=0) at main.c:592
#14 0x00000000002540b9 in main (argc=1, argv=0x820a56568) at main.c:745
I'm running out of ideas what to try to fix this. I'm going to test with the latest commit of xfwm4 and also downgrading some things I upgraded lately (glib was recently updated, I could try downgrading it, just in case)
Any ideas or suggestions?
Edited by Guido Falsi