Path: utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!samsung!spool2.mu.edu!uunet!mcsun!inria!cict!irit!amarger From: amarger@irit.irit.fr (amarger) Newsgroups: comp.windows.x Subject: Problem with XSync ? Keywords: Xsync Message-ID: <1393@irit.irit.fr> Date: 9 Jan 91 16:26:42 GMT Sender: usenet@irit.fr Reply-To: amarger@irit.irit.fr (amarger) Organization: IRIT-UPS, Toulouse, France Lines: 28 Nntp-Posting-Host: lisp I'm working on a SUN4/OS4.0.3 X11R4/MOTIF1.1. I want to synchronize a client with the server So I'm using Xsync(), but it does not work. Is the problem due to X11 or my source code??????? My source code: XSync ( dpy, False); evt_waiting = XPending ( dpy ); while ( evt_waiting ) { XtAppNextEvent ( App_ctxt, &evt ); XtDispatchEvent ( &evt ); XSync ( dpy, False ); evt_waiting = XPending ( dpy ); } Normally, when I'm exiting the loop, all the requests sent to the server, must have been treated by the server. In fact, very often , that's not. And if I wait a while, new events come from the server. What's the matter ???? The problem occurs very often when server and client are on different machines (using an Xterm for example). It's very uncommon when both are on the the same machine.