Help debugging X program (moonlight)
Hi,
[ please keep me on the Cc:, I'm not on -devel atm ]
this is driving me nuts. moonlight segfaults on start up if libGL.so
is utah-glx's instead of regular mesa's. I have recompiled the
bloody thing against utah-glx's libGL.so (it was using some Mesa
extension that utah-glx doesn't provide) and now I'm dealing with
what seems to be a documentation problem... compiled in `development
mode' (that means don't strip the thing a behave a little different),
I'm getting:
[604 ysabell:~/devel/debian/moonlight/moonlight-0.5.3/src] gdb main/.libs/moonlight-0.5.3 core
[...]
(gdb) bt
#0 0x401c5627 in ErrorHandler (display=0x804efa8, event=0xbffff35c)
at XGraphicsSystem.C:138
#1 0x4043ba5d in _XError () from /usr/X11R6/lib/libX11.so.6
#2 0x4043a14b in _XReply () from /usr/X11R6/lib/libX11.so.6
#3 0x404293c3 in XInternAtom () from /usr/X11R6/lib/libX11.so.6
#4 0x401cf84e in set_mwm_border (dpy=0x804efa8, w=41943087)
at set_mwm_border.C:73
[...]
(gdb) list
133
134 #ifndef NDEBUG
135 // crash 'n' burn for debugging purposes
136 char *str;
137 str = NULL;
138 *str = '0';
139 exit(-1);
140 #endif
141
142 return 0;
(gdb) list set_mwm_border.C:73
68 /* setup the property */
69 motif_hints.flags = MWM_HINTS_DECORATIONS;
70 motif_hints.decorations = flags;
71
72 /* get the atom for the property */
73 prop = XInternAtom( dpy, "_MOTIF_WM_HINTS", True );
74 if (!prop) {
75 /* something went wrong! */
76 return;
77 }
(gdb) print *event
$1 = {type = 0, display = 0x804efa8, resourceid = 71, serial = 92,
error_code = 8 '\b', request_code = 1 '\001', minor_code = 0
'\000'}
Error code 8 is (X11/X.h):
#define BadMatch 8 /* parameter mismatch */
but XInternAtom(3x) says:
XInternAtom can generate BadAlloc and BadValue errors.
wtf!
Even more confusing, XRequest.1 is X_CreateWindow. X_InternAtom is
XRequest.16... arrrrggghhh! There's a XCreateWindow a few lines
before the call to XInternAtom, but none of the documented reasons
for a BadMatch generated by XCreateWindow are met.
Help? Anyone?
Marcelo
Reply to: