Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations)
Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations)
- Subject: Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations)
- From: Ben Byer <email@hidden>
- Date: Sun, 18 Nov 2007 16:38:41 -0800
On Nov 18, 2007, at 3:56 PM, Derek Fawcus wrote: Well I consider the redefined contents of DISPLAY to be rather an ugly hack.
Bummer. Why? It should be possible for launchd to listen on the normal :0.0 (/tmp/.X11-unix/:0) for a connection, then when that socket can accept without blocking, spawn an xserver and pass the listening socket to it. Launchd never calling accept on the socket. Then if/when the xserver dies, launchd goes back to waiting for the listening socket to be able to accept without blocking.
I believe that's what it does, currently (with the exception of the part I highlighted in red). An alternate would be for launchd to do the first accept and pass the listen and accepted sockets to the spawned Xserver, closing the accepted socket after the fork and keeping the listening socket open. The Xserver then accepts for new connections, and deals with the initial triggering connection.
The first scheme seems as if it may be easier to hack in to the xserver xtransport stuff, as the server would have a chance to do its xinit stuff before it called accept (i.e. it acts as if it was started before the first connections occurred).
Wait, which problem are you trying to solve, here? The xinit race condition, the changes required to support the new $DISPLAY naming scheme, ? -- Ben Byer CoreOS / BSD Technology Group, XDarwin maintainer
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list (email@hidden)
This email sent to email@hidden