RE: Xlib : unexpected async reply
Have you tried using XInitThreads() -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of [EMAIL PROTECTED] Sent: Monday, February 13, 2006 11:35 AM To: devel@xfree86.org Subject: Xlib : unexpected async reply Iam buildin a kde Application that uses Xlib . Iam using pthread_cond_wait() so that the running worker thread will wait untill the GUI thread give signal or finished his work . But suppose the worker thread blocked some X resources and waiting for the signal . If the next thread need those resources then there going to be problem . So in my case how will ensure that blocked working thread will release all the X resources so that the GUI thread can use that X resources .I have used separate display connection for each thread . I pause the current pthread and invoke an dialog in another thread the following error is coming : >Xlib : unexpected async reply >Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! >X Error : BadImplementation (server does not implement opertaion) 17 > Major opcode : 20 > MInor opcode : 0 > Resource id : 0x759d1 > The error is coming randomly , not always . Can any will help how to come out of this error . Thanks ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel DISCLAIMER This message and any attachment(s) contained here are information that is confidential, proprietary to HCL Technologies and its customers. Contents may be privileged or otherwise protected by law. The information is solely intended for the individual or the entity it is addressed to. If you are not the intended recipient of this message, you are not authorized to read, forward, print, retain, copy or disseminate this message or any part of it. If you have received this e-mail in error, please notify the sender immediately by return e-mail and delete it from your computer ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
Hi to all I have made separate display connection to Xserver for each thread but this is working fine sometimes not always .sometime it fail when i invoke the dialog . can anybody help me to resolve this issues . Thanks 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 Xlib code that accesses the socket so > that only one thread can send data through the socket at a time. > This generally works fine except that if you pause one thread while > it is in Xlib and has already taken the lock, it will prevent any other > thread from entering Xlib and taking the lock. Separate display > connections for each thread are the solution to that. > > Mark. > > > On Wed, 1 Feb 2006 [EMAIL PROTECTED] wrote: > >> Hi >> u have given a good suggestion but I dont understand if the >> pausing thread block any other thread trying to use the >>Xlib with the same display connection then why it is working >> fine sometimes . >> Thanks >> >> Separate threads either need to use separate display >> > connections or you need to enable thread mutexes for a shared >> > connection (XInitThreads will enable Xlib's internal mutexes). >> > Note still, that pausing a thread while it's in Xlib can block >> > any other threads also trying to use Xlib with the same display >> > connection. You'd want to use separate display connections >> > for that. >> > >> >Mark. >> > >> > On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: >> > >> >> Hi to all >> >> >> >> >> >> Iam building an kde Application When I pause the current pthread and >> >> invoke an dialog in another thread the following error is >> coming . >> >> >> >> Xlib : unexpected async reply >> >> Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! >> >> X Error : BadImplementation (server does not implement opertaion) 17 >> >> Major opcode : 20 >> >> MInor opcode : 0 >> >> Resource id : 0x759d1 >> >> The error is coming randomly , not always . >> >> Can any will help how to come out of this error . >> >> >> >> >> >> Thanks >> >> ___ >> >> Devel mailing list >> >> Devel@XFree86.Org >> >> http://XFree86.Org/mailman/listinfo/devel >> >> >> > ___ >> > Devel mailing list >> > Devel@XFree86.Org >> > http://XFree86.Org/mailman/listinfo/devel >> > >> >> ___ >> Devel mailing list >> Devel@XFree86.Org >> http://XFree86.Org/mailman/listinfo/devel >> > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
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 Xlib code that accesses the socket so that only one thread can send data through the socket at a time. This generally works fine except that if you pause one thread while it is in Xlib and has already taken the lock, it will prevent any other thread from entering Xlib and taking the lock. Separate display connections for each thread are the solution to that. Mark. On Wed, 1 Feb 2006 [EMAIL PROTECTED] wrote: > Hi > u have given a good suggestion but I dont understand if the > pausing thread block any other thread trying to use the >Xlib with the same display connection then why it is working > fine sometimes . > Thanks > > Separate threads either need to use separate display > > connections or you need to enable thread mutexes for a shared > > connection (XInitThreads will enable Xlib's internal mutexes). > > Note still, that pausing a thread while it's in Xlib can block > > any other threads also trying to use Xlib with the same display > > connection. You'd want to use separate display connections > > for that. > > > > Mark. > > > > On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: > > > >> Hi to all > >> > >> > >> Iam building an kde Application When I pause the current pthread and > >> invoke an dialog in another thread the following error is coming . > >> > >> Xlib : unexpected async reply > >> Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! > >> X Error : BadImplementation (server does not implement opertaion) 17 > >> Major opcode : 20 > >> MInor opcode : 0 > >> Resource id : 0x759d1 > >> The error is coming randomly , not always . > >> Can any will help how to come out of this error . > >> > >> > >> Thanks > >> ___ > >> Devel mailing list > >> Devel@XFree86.Org > >> http://XFree86.Org/mailman/listinfo/devel > >> > > ___ > > Devel mailing list > > Devel@XFree86.Org > > http://XFree86.Org/mailman/listinfo/devel > > > > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
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 (0,"dpause");//here fails paused_dialog->show(); } pause() { int rc = pthread_create( &thread5, &attr, dpause, NULL ); rc= pthread_join(thread5 ,&thr_retval ) ; while (pause_rec == 0 ) { sleep(1); } if(pause_rec==1) { XCloseDisplay (display); pthread_exit(&thread5 ) ; } } plz give some suggestion to solve this problem . Thanks >> What do you mean by separate display connections" ? >> The case is this : >> >>I mean a display connection returned by XOpenDisplay. >> >> > > Right. I think what Carsten is saying is, if you might need to pause a > thread in the middle of Xlib, then that thread needs to make its own > call to XOpenDisplay, so that it has its own connection, separate from > the rest of the application. > > -- > Tim Roberts, [EMAIL PROTECTED] > Providenza & Boekelheide, Inc. > > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
[EMAIL PROTECTED] wrote: > What do you mean by separate display connections" ? > The case is this : > >I mean a display connection returned by XOpenDisplay. > > Right. I think what Carsten is saying is, if you might need to pause a thread in the middle of Xlib, then that thread needs to make its own call to XOpenDisplay, so that it has its own connection, separate from the rest of the application. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
Hi thanks for replying quickly What do you mean by separate display connections" ? The case is this : I mean a display connection returned by XOpenDisplay. Thanks >> u have given a good suggestion but I dont understand if the >> pausing thread block any other thread trying to use the >>Xlib with the same display connection then why it is working >> fine sometimes . >> Thanks > > that's life debugging and problems with threads. mostly you might be lucky > and > the threads don't clash and it HAPPENS to work - by sheer luck. when they > do > clash you end up with these "weird problems that happen sometimes" - ie > concurrency/locking issues. > >> Separate threads either need to use separate display >> > connections or you need to enable thread mutexes for a shared >> > connection (XInitThreads will enable Xlib's internal mutexes). >> > Note still, that pausing a thread while it's in Xlib can block >> > any other threads also trying to use Xlib with the same display >> > connection. You'd want to use separate display connections >> > for that. >> > >> >Mark. >> > >> > On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: >> > >> >> Hi to all >> >> >> >> >> >> Iam building an kde Application When I pause the current pthread and >> >> invoke an dialog in another thread the following error is >> coming . >> >> >> >> Xlib : unexpected async reply >> >> Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! >> >> X Error : BadImplementation (server does not implement opertaion) 17 >> >> Major opcode : 20 >> >> MInor opcode : 0 >> >> Resource id : 0x759d1 >> >> The error is coming randomly , not always . >> >> Can any will help how to come out of this error . >> >> >> >> >> >> Thanks >> >> ___ >> >> Devel mailing list >> >> Devel@XFree86.Org >> >> http://XFree86.Org/mailman/listinfo/devel >> >> >> > ___ >> > Devel mailing list >> > Devel@XFree86.Org >> > http://XFree86.Org/mailman/listinfo/devel >> > >> >> ___ >> Devel mailing list >> Devel@XFree86.Org >> http://XFree86.Org/mailman/listinfo/devel >> > > > -- > - Codito, ergo sum - "I code, therefore I am" -- > The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] > $BMg9%B?(B > Tokyo, Japan ($BEl5~(B $BF|K\(B) > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
On Wed, 1 Feb 2006 22:18:49 -0800 (PST) [EMAIL PROTECTED] babbled: > Hi > u have given a good suggestion but I dont understand if the > pausing thread block any other thread trying to use the >Xlib with the same display connection then why it is working > fine sometimes . > Thanks that's life debugging and problems with threads. mostly you might be lucky and the threads don't clash and it HAPPENS to work - by sheer luck. when they do clash you end up with these "weird problems that happen sometimes" - ie concurrency/locking issues. > Separate threads either need to use separate display > > connections or you need to enable thread mutexes for a shared > > connection (XInitThreads will enable Xlib's internal mutexes). > > Note still, that pausing a thread while it's in Xlib can block > > any other threads also trying to use Xlib with the same display > > connection. You'd want to use separate display connections > > for that. > > > > Mark. > > > > On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: > > > >> Hi to all > >> > >> > >> Iam building an kde Application When I pause the current pthread and > >> invoke an dialog in another thread the following error is coming . > >> > >> Xlib : unexpected async reply > >> Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! > >> X Error : BadImplementation (server does not implement opertaion) 17 > >> Major opcode : 20 > >> MInor opcode : 0 > >> Resource id : 0x759d1 > >> The error is coming randomly , not always . > >> Can any will help how to come out of this error . > >> > >> > >> Thanks > >> ___ > >> Devel mailing list > >> Devel@XFree86.Org > >> http://XFree86.Org/mailman/listinfo/devel > >> > > ___ > > Devel mailing list > > Devel@XFree86.Org > > http://XFree86.Org/mailman/listinfo/devel > > > > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] 裸好多 Tokyo, Japan (東京 日本) ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
Hi u have given a good suggestion but I dont understand if the pausing thread block any other thread trying to use the Xlib with the same display connection then why it is working fine sometimes . Thanks Separate threads either need to use separate display > connections or you need to enable thread mutexes for a shared > connection (XInitThreads will enable Xlib's internal mutexes). > Note still, that pausing a thread while it's in Xlib can block > any other threads also trying to use Xlib with the same display > connection. You'd want to use separate display connections > for that. > > Mark. > > On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: > >> Hi to all >> >> >> Iam building an kde Application When I pause the current pthread and >> invoke an dialog in another thread the following error is coming . >> >> Xlib : unexpected async reply >> Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! >> X Error : BadImplementation (server does not implement opertaion) 17 >> Major opcode : 20 >> MInor opcode : 0 >> Resource id : 0x759d1 >> The error is coming randomly , not always . >> Can any will help how to come out of this error . >> >> >> Thanks >> ___ >> Devel mailing list >> Devel@XFree86.Org >> http://XFree86.Org/mailman/listinfo/devel >> > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
Separate threads either need to use separate display connections or you need to enable thread mutexes for a shared connection (XInitThreads will enable Xlib's internal mutexes). Note still, that pausing a thread while it's in Xlib can block any other threads also trying to use Xlib with the same display connection. You'd want to use separate display connections for that. Mark. On Tue, 31 Jan 2006 [EMAIL PROTECTED] wrote: > Hi to all > > > Iam building an kde Application When I pause the current pthread and > invoke an dialog in another thread the following error is coming . > > Xlib : unexpected async reply > Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! > X Error : BadImplementation (server does not implement opertaion) 17 > Major opcode : 20 > MInor opcode : 0 > Resource id : 0x759d1 > The error is coming randomly , not always . > Can any will help how to come out of this error . > > > Thanks > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib : sequence lost (0x1718e > 0x71a0) in reply to 0x0!
On Tue, 31 Jan 2006 22:36:23 -0800 (PST) [EMAIL PROTECTED] babbled: > Hi to all > > > Iam building an kde Application When I pause the current pthread and > invoke an dialog in another thread the following error is coming . application is using the same x display connection from multipel htreads without any locking or enablign threadsafeness in xlib. it's an application problem as such so you should direct this to the authors of that application or the particular toolkit(s) it depends on that may create such silent threads. > Xlib : unexpected async reply > Xlib :sequence lost (0x1718e > 0x71a0) in reply to 0x0! > X Error : BadImplementation (server does not implement opertaion) 17 > Major opcode : 20 > MInor opcode : 0 > Resource id : 0x759d1 > The error is coming randomly , not always . > Can any will help how to come out of this error . > > > Thanks > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] 裸好多 Tokyo, Japan (東京 日本) ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: xlib
On Tue, 21 Jun 2005 05:18:19 -0700 [EMAIL PROTECTED] babbled: > Hello, > > Would you also happen to know the API to force the Xserver to reload the > calibration values. I need to have the Xserver pick up the re-calibration > values without having to restart the Xserver. XVidmode? > Any help would be appreciated. > > Thank You. > > Regards, > Sudeep V > > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of > Carsten Haitzler > Sent: Tuesday, June 21, 2005 5:33 PM > To: MANJUNATHA P > Cc: devel@XFree86.Org > Subject: Re: xlib > > > On Tue, 21 Jun 2005 04:20:16 -0700 MANJUNATHA P <[EMAIL PROTECTED]> > babbled: > > > Hi, > > I want to capture particular region of desktop window in Linux plat form. > > can anybody suggest me how it can be done,using xlib? > > X(Shm)GetImage(); > > -- > - Codito, ergo sum - "I code, therefore I am" -- > The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] > 裸好多 [EMAIL PROTECTED] > Tokyo, Japan (東京 日本) > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > ___ > Devel mailing list > Devel@XFree86.Org > http://XFree86.Org/mailman/listinfo/devel > -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] 裸好多 [EMAIL PROTECTED] Tokyo, Japan (東京 日本) ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
RE: xlib
Hello, Would you also happen to know the API to force the Xserver to reload the calibration values. I need to have the Xserver pick up the re-calibration values without having to restart the Xserver. Any help would be appreciated. Thank You. Regards, Sudeep V -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Carsten Haitzler Sent: Tuesday, June 21, 2005 5:33 PM To: MANJUNATHA P Cc: devel@XFree86.Org Subject: Re: xlib On Tue, 21 Jun 2005 04:20:16 -0700 MANJUNATHA P <[EMAIL PROTECTED]> babbled: > Hi, > I want to capture particular region of desktop window in Linux plat form. > can anybody suggest me how it can be done,using xlib? X(Shm)GetImage(); -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] 裸好多 [EMAIL PROTECTED] Tokyo, Japan (東京 日本) ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: xlib
On Tue, 21 Jun 2005 04:20:16 -0700 MANJUNATHA P <[EMAIL PROTECTED]> babbled: > Hi, > I want to capture particular region of desktop window in Linux plat form. > can anybody suggest me how it can be done,using xlib? X(Shm)GetImage(); -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)[EMAIL PROTECTED] 裸好多 [EMAIL PROTECTED] Tokyo, Japan (東京 日本) ___ Devel mailing list Devel@XFree86.Org http://XFree86.Org/mailman/listinfo/devel
Re: Xlib: extension "GLX" missing on display "simon4:50.0" while printing
Your app apparently requires OpenGL support. If XFree86 is your X-server, you need to add: Load "glx" to the Section "Module" of the XF86Config file. Mark. On Fri, 5 Nov 2004, Simon Toedt wrote: > Hello, > > After adding a print support to our application I am getting the > following warning from our application before it crashes > > (XPSERVERLIST=simon:50 ./wasp_core) > probing > loading 3D environment > loading plugins... >flash. . . x > print > Xlib: extension "GLX" missing on display "simon4:50.0". > ./wasp_core: Error: couldn't get an RGB, Double-buffered visual. > > evey time I run the application. What does this mean and what must i > do to get rid of it. I am using the GISWxprintglue package on Solaris > 8 with all the newest set of patches from Sunsolve. > > Simon > ___ > Devel mailing list > [EMAIL PROTECTED] > http://XFree86.Org/mailman/listinfo/devel > ___ Devel mailing list [EMAIL PROTECTED] http://XFree86.Org/mailman/listinfo/devel
Re: xlib window resizing
On Tue, 4 Nov 2003 18:50:16 -0500 Ricardo Baratto <[EMAIL PROTECTED]> (Bbabbled: (B (B> hi all, (B> (B> in an xlib app i'm using ResizeRequest events to figure out when the (B> user has changed the window size and then repaint the contents. (B> (the contents of the window are scaled down to fit its current size, something (B> like zoom-in and zoom-out). While playing with the redraw code i noticed that (B> when i resize the window to its original size, the app doesn't receive any (B> ResizeRequest messages. Only expose events are sent, and my app of course (B> doesn't redraw the contents appropiately for the new (original) size (B> (B> is this normal behavior? if yes, which event(s) do i need to listen for in (B> order to know that the window is back to its original size? (B (Buse configurenotify events, not resizrequest :) (B (B (B-- (B--- Codito, ergo sum - "I code, therefore I am" (BThe Rasterman (Carsten Haitzler)[EMAIL PROTECTED] $B7'<*(B - $Bhttp://XFree86.Org/mailman/listinfo/devel