Hello,
I've had intermittent problems with the "mwm" window manager,
when I issue a ctrl-d sequence on the failsafe client. (I use
xdm to get the server started and xterm as the failsafe client)
The mwm process does not get killed and loops indefinitely.
After some amount of debugging I've narrowed the problem down
to the "_XEventsQueued ()" routine in XlibInt.c. Here the
routine issues an FIONREAD ioctl to determine the number of
bytes left to be read. It also seems to rely on the ioctl
to detect a broken connection. In my case, the server has closed
down the slave side of the connection but the ioctl does not
detect it. It returns 0 bytes to be read and returns the number
of events already queued.
In short the scenario is something like this,
.....
poll () returns 1 with POLLIN (the zero byte message sent by the slave pts module)
ioctl (fd, FIONREAD, &pend) returns 0 with pend = 0
... ad inifinitum...
Now, it seems there is some code within _XEventsQueued () to detect
this scenario compiled with the XCONN_CHECK_FREQ option (In my case
mwm is compiled with this option with XCONN_CHECK_FREQ == 256).
Unfortunately this block of code never gets executed because there
are events already queued. The following code snippet from _XEventsQueued ()
should clarify this
_XEventsQueued ()
{
_______________________________________________
Xpert mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/xpert