Commit Graph

87 Commits

Author SHA1 Message Date
Jamey Sharp 3cc0ddf0e6 Fix bug #7261: events do not signal the end of replies for that sequence number. 2006-09-18 14:49:22 -07:00
Jamey Sharp a92716f1da Finish removing deprecated functions. Fixes build failure (oops). 2006-09-13 12:15:23 -07:00
Josh Triplett 13896d8f65 Fix typo: s/request/sequence/ 2006-07-30 15:09:03 -07:00
Josh Triplett 685d8c76c2 Add XCBRequestCheck function needed for Plan 7. 2006-07-30 14:42:55 -07:00
Keith Packard db2504130b Switch sequence comparisons to handle 32-bit sequence number wrap.
Create a macro, XCB_SEQUENCE_COMPARE, that accepts two sequence numbers and
a comparison operator and correctly handles 32-bit wrap around.
Rewrite all ordered sequence number comparisons to use this macro.
Also, caught one error where a sequence was stored in a signed int variable.
Push out a GetInputFocus request when the sequence number does wrap at 32
bits so that applications cannot see sequence 0 (as that is an error
indicator).
2006-07-01 00:16:07 -07:00
Jamey Sharp 771761ccaa Minor performance improvement: do not call _xcb_in_expect_reply unless it is needed. It is not often needed. 2006-04-20 11:51:01 -07:00
Jamey Sharp 8953a14f2b Add <sys/select.h> to xcb_in.c to fix bug #6122. 2006-04-19 22:48:10 -07:00
Jamey Sharp f090da98f3 Remove the last goto in XCB: XCBWaitForReply now permits multiple threads to force the same cookie. 2006-04-19 20:31:20 -07:00
Jamey Sharp d5347485a5 Restructure XCBWaitForReply to eliminate two gotos. 2006-04-19 20:23:37 -07:00
Jamey Sharp d5ab03b4b7 Fixed poll_for_reply, added comments, and refactored XCBWaitForReply to call poll_for_reply. 2006-04-19 20:15:15 -07:00
Jamey Sharp 7667adbc63 Add XCBPollForReply and deprecate XCBGetRequestRead and XCBGetQueuedRequestRead. 2006-04-19 16:49:32 -07:00
Eric Anholt 8275ac3a4a Retry a select() if it returns with EINTR. Fixes IO errors in Xephyr, which is
often interrupted by timers.
2006-04-09 19:51:10 -07:00
Jamey Sharp d69c403cba Merge branch 'master' of git+ssh://git.freedesktop.org/git/xcb 2006-03-12 13:36:33 -08:00
Jamey Sharp fb61c94d68 Remove c->out.vec. Pass iovecs directly down the call tree. Add _xcb_out_flush_to, refactor other functions, make write_block static. 2006-03-12 12:40:34 -08:00
Jamey Sharp 83e652f566 Move c->out.vec refs out of _xcb_conn_wait up to _xcb_out_flush. 2006-03-09 00:02:42 -08:00
Ian Osgood 1261a4150c Add symbols for error and reply response_types,
and use XCBKeymapNotify from xcb-proto.
2006-03-08 22:26:20 -08:00
Jamey Sharp e5458e477d Implement provably-correct sequence wrap handling. Add flag XCB_REQUEST_DISCARD_REPLY. 2006-03-05 00:20:50 -08:00
Jamey Sharp 29f9fe0fc8 API/ABI change: XCBSendRequest returns the sequence number instead of using an out-parameter. Now 0 is a special sequence number indicating failure. 2006-03-03 11:08:10 -08:00
Jamey Sharp 255c21b17f Add 32-bit full_sequence fields to generic errors and events, so callers can always correlate events and errors with requests correctly. 2006-03-03 01:45:00 -08:00
Jamey Sharp ed823bf651 Separate notion of request-completed from current-request, and mark requests completed more aggressively. Detects some usage errors that are otherwise undetectable. 2006-03-02 13:49:00 -08:00
Jamey Sharp 5e350126a7 Bugfix: how about *not* leaking all pending_replies when no reply matches, as often happens with Xlib? 2006-02-27 10:53:08 -08:00
Jamey Sharp 76ad79a7ad Replace readers generic list with hand-written typesafe version. 2006-02-27 01:43:07 -08:00
Jamey Sharp fa71b9b835 Rename struct XCBReplyData to reader_list to follow my naming conventions and better reflect its purpose. 2006-02-27 01:06:15 -08:00
Jamey Sharp ff665b5726 In struct XCBReplyData, change void *data to pthread_cond_t *data. That was dumb. 2006-02-27 00:54:59 -08:00
Jamey Sharp 86ce18c22c Replace current_reply generic queue with hand-written version. No generic queues remain so delete their implementation. 2006-02-26 22:58:17 -08:00
Jamey Sharp 0f130b4d94 Replace events generic queue with hand-written typesafe version. 2006-02-26 18:28:50 -08:00
Jamey Sharp ff7b6c9124 API/ABI break: Add flags to XCBSendRequest, first for error-checked requests.
There's no more race condition between event and reply handling.
The *RequestBlind and *RequestChecked functions are not yet implemented.
2006-02-26 15:45:08 -08:00
Jamey Sharp 7875040fa1 Replace pending_replies generic queue with a hand-implemented typesafe version. 2006-02-26 02:00:03 -08:00
Jamey Sharp 46a7549981 XCB has not had tracing features for a long time: remove the remnants. 2006-02-25 23:27:47 -08:00
Jamey Sharp 67b2649dc4 Move _xcb_read_block to xcb_in.c and make it static. Change calls in xcb_conn.c to _xcb_in_read_block instead. 2006-02-24 01:40:45 -08:00
Jamey Sharp e1c2777aba Coalesce readn into _xcb_in_read and simplify. 2006-02-24 00:59:08 -08:00
Jamey Sharp 3f8d0bd532 Move _xcb_readn to xcb_in.c and make it static. Minor change to _xcb_read_block to not depend on _xcb_readn. 2006-02-24 00:48:18 -08:00
Jamey Sharp 6149c7a6b5 More return value changes, and make _xcb_in_read_packet static since it is not called from outside xcb_in.c. 2006-02-23 12:15:09 -08:00
Jamey Sharp 5b1d39e27b More return value changes. 2006-02-23 11:50:12 -08:00
Jamey Sharp 662479760c Make the return value of _xcb_conn_wait boolean, instead of syscall-like. 2006-02-23 10:17:40 -08:00
Jamey Sharp 5b7182c659 Workaround X server bug, fd.o #3210: if a GLXGetFBConfigs request is sent, fix the length field in the reply. 2006-02-18 18:12:40 -08:00
Josh Triplett 47ceed7861 Remove xcl and CVSROOT. 2006-02-18 16:49:41 -08:00