Bug 6105 - Errors and events should include their 32-bit sequence number
Summary: Errors and events should include their 32-bit sequence number
Status: RESOLVED MOVED
Alias: None
Product: XCB
Classification: Unclassified
Component: Library (show other bugs)
Version: unspecified
Hardware: All All
: medium enhancement
Assignee: Jamey Sharp
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-03-03 18:26 UTC by Jamey Sharp
Modified: 2019-02-16 19:41 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Jamey Sharp 2006-03-03 18:26:36 UTC
Currently, XCB hands errors and events back to the caller exactly as they were
read off the wire. This should be changed to hand back an additional four bytes
with the full 32-bit sequence number. For compatibility with XCBGenericReply and
Xlib's xReply/xEvent/xError, I'd like to add this new field after the raw bytes.
Comment 1 Jamey Sharp 2006-03-03 19:07:30 UTC
The XSLT in c-client.xsl probably ought to generate structures with
full_sequence elements at the end, so that the full sequence number is
accessible without casting back to XCBGenericEvent or XCBGenericError. I don't
know how to do that correctly. Probably we need to track the size in bytes for
every type in the X protocol, so that we can tell how much padding to insert
before the full_sequence field.
Comment 2 Uli Schlachter 2012-09-14 12:55:25 UTC
This seems like it was fixed ages ago with the full_sequence field:

commit 255c21b17f61147388bab6e1d42623a008a4a8d2
Author: Jamey Sharp <jamey@minilop.net>
Date:   Fri Mar 3 01:45:00 2006 -0800

    Add 32-bit full_sequence fields to generic errors and events, so callers can always correlate events and errors with requests correctly.

However, since this commit is from the very same day that this bug report is from, I feel like I missed something. What did I miss that stops this from getting closed?
Comment 3 Daniel Martin 2013-02-17 00:30:46 UTC
1. The field is missing on replies. (comment #0)
2. To access the field one still needs to cast the event or error to xcb_generic_event_t or xcb_generic_error_t. (comment #1)

Atm. I'm looking at it (for XI2), because it's injected at the 32b boundary of the structure and this causes problems with X Generic Events bigger then that.
Comment 4 Daniel Martin 2013-02-17 13:58:08 UTC
(In reply to comment #3)
> 1. The field is missing on replies. (comment #0)
> 2. To access the field one still needs to cast the event or error to
> xcb_generic_event_t or xcb_generic_error_t. (comment #1)
> 
> Atm. I'm looking at it (for XI2), because it's injected at the 32b boundary
> of the structure and this causes problems with X Generic Events bigger then
> that.

An attempt to fix the XGEs and the other 2 open points on the way:
    [RFC libxcb 0/2] full sequence for everyone
    http://lists.freedesktop.org/archives/xcb/2013-February/008165.html
Comment 5 GitLab Migration User 2019-02-16 19:41:38 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xorg/lib/libxcb/issues/29.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.