Tracking down X11 errors? Topic is solved

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
Post Reply
Knows some wx things
Knows some wx things
Posts: 32
Joined: Wed Nov 12, 2008 7:04 pm

Tracking down X11 errors?

Post by smf » Fri Mar 20, 2009 11:21 am


I have spurious X11 errors in my App. These happen to be reported asynchronously, so it is said to trace them with running the App with the "--sync" commandline-switch...

hmm,... either --sync is just ignored by wxApps, or I do not understand how to start a wxApp in sync-mode. Anyone here, who could point me to the right method of debugging this kind of errors? How do I trace these in gdb or ddd without --sync?

I really need to know were in my code things go wrong...


wxWorld Domination!
wxWorld Domination!
Posts: 1195
Joined: Thu Feb 22, 2007 4:47 pm
Location: Denver, Co

Post by mc2r » Sun Mar 22, 2009 6:19 am

"--sync" is probably ignored by wxWidgets. I don't have a way to test it right now and haven't ever had a need to check to see if it was there.

GTK apps call XSynchronize(), when --sync is passed. I'm not sure how you'd go about getting the Display* from wxWidgets. Probably going to have to do more GTK/Z11 specific code for that.

XSynchronize() is in Xlib.h

Lastly there maybe a global variable _Xdebug that you can set to TRUE in your debugger. I'd check that first before trying to go the XSynchronize() route.

Hope some of that helped.


Post Reply