Bug 63158 - screensaver notify event specification is incorrect
Summary: screensaver notify event specification is incorrect
Status: RESOLVED FIXED
Alias: None
Product: XCB
Classification: Unclassified
Component: Protocol (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: xcb mailing list dummy
QA Contact: xcb mailing list dummy
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-05 11:16 UTC by raymondwagenmaker
Modified: 2013-05-28 06:31 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description raymondwagenmaker 2013-04-05 11:16:33 UTC
screensaver.xml contains the following specification:

  <event name="Notify" number="0">
    <field type="CARD8" name="code"/>
    <field type="BYTE" name="state"/>    <!-- enum State -->
    <pad bytes="1" />
    <field type="CARD16" name="sequence_number"/>
    <field type="TIMESTAMP" name="time"/>
    <field type="WINDOW" name="root"/>
    <field type="WINDOW" name="window"/>
    <field type="BYTE" name="kind"/>     <!-- enum Kind -->
    <field type="BOOL" name="forced"/>
    <pad bytes="14"/>
  </event>

The sequence_number is added automatically when the struct type is generated (but then it is called sequence). Similarly, the code field is what xcb calls response_type. These fields should not be specified in the XML file. I also do not know why the 1-byte padding is there (added for v1.1 extension update); maybe to hide symptoms resulting from the duplicate fields?

This was pointed out when screensaver.xml was first submitted [1] but apparently it has never been fixed; seems like I am the first to actually use the screensaver extension with xcb.

[1] http://lists.freedesktop.org/archives/xcb/2005-July/000910.html
Comment 1 Daniel Martin 2013-05-28 06:31:22 UTC
Thanks for your detailed report. You're totally right with your comment - those fields shouldn't be there. Now, it's fixed:
    a50670c screensaver: Remove wrong fields from Notify event


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.