[Xcb] [PATCH proto 1/8] present: specify length of RedirectNotify.notifies
Christian Linhart
chris at demorecorder.com
Thu Sep 4 08:48:55 PDT 2014
The list "notifies" of the event RedirectNotify didn't have
a length.
The missing length has caused uncompilable C-Code with our
event-acessors patch because the length-acessor for that list
has used an undeclared variable for the list-length.
Having a length for that list is good anyways for ease of use.
Since the event doesn't contain a field which specifies the
length of the list, the length is derived from the length
of the event.
spec:
http://cgit.freedesktop.org/xorg/proto/presentproto/tree/presentproto.txt?id=presentproto-1.0#n429
http://cgit.freedesktop.org/xorg/proto/presentproto/tree/presentproto.txt?id=presentproto-1.0#n710
note:
The event definition starting at line 429 lists the relationship between
length of event ( "length" ) and length of list ( "n" )
as 17+2n where as the definition starting at line 710
lists 18+2n. The latter is correct according to my verification.
The spec should be fixed.
---
src/present.xml | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/src/present.xml b/src/present.xml
index a9adc2b..95fee01 100644
--- a/src/present.xml
+++ b/src/present.xml
@@ -195,11 +195,19 @@ <event name="RedirectNotify" number="3" xge="true">
<field type="FENCE" name="wait_fence" />
<field type="FENCE" name="idle_fence" />
<field type="CARD32" name="options" />
<pad bytes="4"/>
<field type="CARD64" name="target_msc" />
<field type="CARD64" name="divisor" />
<field type="CARD64" name="remainder" />
- <list type="Notify" name="notifies"/>
+ <list type="Notify" name="notifies">
+ <op op="/">
+ <op op="-">
+ <fieldref>length</fieldref>
+ <value>18</value>
+ </op>
+ <value>2</value>
+ </op>
+ </list>
</event>
</xcb>
--
2.0.1
More information about the Xcb
mailing list