Why is XSetStandardProperties freezing?

Adam Jackson ajax at redhat.com
Mon Jun 18 07:56:28 PDT 2012


On Thu, 2012-06-14 at 13:52 +0100, Myrosia Dzikovska wrote:
> Hi,
> 
> I have a program using an X graphics library that works on FC 13 and
> ScientificLinux 6, but freezes on OpenSuse 12.1.  I need to get it
> running, and I am trying to determine the cause of failure. I'm not an
> X developer, and because the library is complex, I am struggling to
> come up with a minimal example.
> 
> The specific cause of the problem is the call in the code:
> XSetStandardProperties(win->theDisp, win->theWindow, wname, hgraf,
> None, NULL, 0, &(win->hints));
> 
> I verified by putting print statements around it that it never
> returns, the program freezes there.
> 
> The initialization code is complex, but the best I can tell it boils down to
> char *hgraf = "HGraf";
> win->theDisp = XOpenDisplay(0)
> win->theScreen=DefaultScreen(win->theDisp);
> win->rootW=RootWindow(win->theDisp, win->theScreen);
> win->theWindow = XCreateSimpleWindow(win->theDisp, win->rootW, x, y,
> w, h, bw, black, white );
> 
> 
> I am at a loss as to what I should be checking here, and what could
> cause the program to hang at that XSetStandardProperties call, with no
> error messages or exceptions. How can I debug this?

I would probably start by calling XSynchronize(dpy, 1) just after
XOpenDisplay, to see if that changes where the hang happens.

Another strategy would be to compare the generated X protocol between
the OSes that work and the ones that don't.  You can use wireshark for
this if you set DISPLAY=localhost:0 (and didn't start your X server with
-nolisten tcp); alternatively, there's xscope(1).

Are you using the same window manager across all systems?  If not,
that's a pretty likely place to start looking.

- ajax
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg/attachments/20120618/50bee958/attachment.pgp>


More information about the xorg mailing list