[Xcb] [PATCH] Fail if fd is too big and poll() is not available

Rémi Denis-Courmont remi at remlab.net
Sun Mar 28 10:44:52 PDT 2010

On Sunday 28 March 2010 20:36:50 Jamey Sharp, you wrote:
> 2010/3/28 Rémi Denis-Courmont <remi at remlab.net>:
> > On Saturday 27 March 2010 02:20:07 Jamey Sharp, you wrote:
> >> Makes sense to me, except... Shouldn't the test for a too-big fd be in
> >> xcb_conn.c somewhere instead? An application might open the connection
> >> itself, bypassing the code in util.
> >
> > Good point. Hopefully corrected patch.
> Yeah, that's good, but now it doesn't seem right to close a file
> descriptor that we didn't open.

AFAICT, this possibility should simply be specified. If XCB sent something 
(e.g. for authentication) and then failed, there is not much to do but close 
the socket, even if XCB did not open it by itself.

Rémi Denis-Courmont

More information about the Xcb mailing list