[Xcb] Why is an explicit xcb_flush needed?

Nicholas Allen nick.allen at onlinehome.de
Tue Mar 30 00:36:24 PDT 2010

Ok, thanks for the explanation. If that's the case then this deadlocking
bug I'm experiencing is most likely in the core XCB library and not the
properties utility library then right? When I get this deadlock the
stack trace shows that xcb_property_changed calls xcb_wait_for_reply and
this never returns. If a flush is not needed before xcb_wait_for_reply
then it can't be because the property library is not flushing correctly.



Josh Triplett wrote:
> You don't need to call xcb_flush prior to xcb_wait_for_reply;
> xcb_wait_for_reply will flush if you try to wait on a reply for a
> request that XCB hasn't sent yet.
> You need to call xcb_flush prior to xcb_wait_for_event, if and only if
> you expect an event that will only occur after XCB sends a particular
> request, and you haven't done anything else to guarantee the flush of
> that request.
> Does that make sense?
> - Josh Triplett

More information about the Xcb mailing list