Hi
Thanks for quick reply. I have did according to ur suggestion
call to XOpenDisplay for the new thread .
But again it is working fine sometime . This is code, that I have
did .
*dpause (void *arg)
{
display = XOpenDisplay ( 0 );
pausem *paused_dialog = new pausem
Each call to XOpenDisplay opens a new communication socket to
the X-server. Commands sent through this socket need to be serialized.
If you have two threads trying to send data at the same time through
the same socket they will corrupt each other's data. XInitThreads
enables a lock around the