NCW

Foreshortened

Close-up views of Nicholas Wilson

+1: I hate Xlib and so should you

I hate Xlib too. It’s got just enough ugly bits to make me upset. XSetIOErrorHandler has me very upset; it’s simply unacceptable not to be able to cleanly exit from a shut down server without leaking. I want to transparently reattach myself to another X server! I did some more tinkering today with this for x11vnc (or rather, our proprietary improvement of it, vncserver-x11), and it’s just not possible to get it working reliably. Deep inside Xlib, it crashes randomly when I try to re-attach to another server. Very unsatisfactory. I think the best bet will be to split the code into three processes, the server using only XCB to access its shared handle to a pixbuf from an SDesktop slave (Xlib), and an Xlib UI client. What a mess. It’s easier to prototype that way than trying to port the whole of our code, a big historic Xlib application, to the new XCB bindings. It would also have the advantage of prototyping an SDesktopIpc/SServerIpc coupling, which is a required part of the solution on Windows to maintaining connections over session changes.