I am observing a problem with OpenGL and Xlib functions on Linux. I have an application which creates windows and draws random curves on them. A single instance of this application works fine with any number of windows. However, if I launch 2 instances of this application, one on each core of a dual-core CPU(using setaffinity), I am observing that one window of each instance goes blank and does not draw, while all other windows of both the instances continue drawing the curves properly.

I am observing a problem with OpenGL and Xlib functions on Linux. I have an application which creates windows and draws random curves on them. A single instance of this application works fine with any number of windows. However, if I launch 2 instances of this application, one on each core of a dual-core CPU(using setaffinity), I am observing that one window of each instance goes blank and does not draw, while all other windows of both the instances continue drawing the curves properly.

I would check to see if you are blocked in XNextEvent, and if so trace from there.

I would check to see if you are blocked in XNextEvent, and if so trace from there. [/QUOTE]

Thanks for the input, but i’m afraid that its not blocked on the XNextEvent. Rather, the Redraw() function is actually called for the window that is apparently blank. But somehow, the second instance is causing one window in each instance to stop drawing. Its as if the head, ‘h’ miraculously becomes invalid for those windows! Tried multiple debugging options. Even called Redraw() from the ConfigureNotify event, and saw that it was called on resizing the window, but even that did not stop the windows from being blank. The wierd part is that all windows were drawing fine until the second instance was launched, so it could not be a case of a corrupt handle as well.