[Xcb] [PATCH 2/3] Do not block when calling reply() multiple times.

Peter Harris pharris at opentext.com
Tue Feb 2 13:50:53 PST 2010

On 2010-02-02 16:05, Julien Danjou wrote:
> At 1265143814 time_t, Peter Harris wrote:
>> My current beef with the patch is that it requires horrible typecast
>> gymnastics to convert a specific cookie type to an xcb_void_cookie_t.
>> I'm not sure if that can be fixed without either breaking existing apps
>> or adding a gazillion request-specific discard functions.
> Just ask for the sequence rather than the cookie.
> This is how it is done in various place like xcb_wait_for_reply().

Yeah, but xcb_wait_for_reply is an implementation detail. None of the
documented API take a sequence number. The cookie is opaque, publicly.

That said, we could document the contents of cookies and ask for the
sequence number. But that doesn't feel any less bad than the horrible
typecast gymnastics. Or maybe I'm over-thinking things.

Peter Harris
               Open Text Connectivity Solutions Group
Peter Harris                    http://connectivity.opentext.com/
Research and Development        Phone: +1 905 762 6001
pharris at opentext.com            Toll Free: 1 877 359 4866

More information about the Xcb mailing list