summaryrefslogtreecommitdiff
path: root/xts5
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2010-06-25 14:35:58 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2010-06-25 16:16:27 +1000
commit9da20dd6962d6704f4c3517993b633392a3efadd (patch)
tree4289033436ffe26871246c643caea426ca90afcc /xts5
parentfde1dff26bf796365645750386dbe713146cd9df (diff)
Xlib12: Add GenericEvent to list of permitted events.
Fixes error message "_xgeEventToWire: Unknown extension -1, this should never happen." on Xlib12 XSendEvent 21. This requires expanding the global event_type array to LASTEvent - 2 instead of the current hardcoded 32. Since the first two opcodes are used for replies and errors, two minus the last event opcode is sufficient. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'xts5')
-rw-r--r--xts5/Xlib12/XSendEvent.m3
-rw-r--r--xts5/src/lib/XInput.c2
2 files changed, 3 insertions, 2 deletions
diff --git a/xts5/Xlib12/XSendEvent.m b/xts5/Xlib12/XSendEvent.m
index 8e527edc..8296b771 100644
--- a/xts5/Xlib12/XSendEvent.m
+++ b/xts5/Xlib12/XSendEvent.m
@@ -151,7 +151,8 @@ static int event_types[] = {
SelectionNotify,
ColormapNotify,
ClientMessage,
- MappingNotify
+ MappingNotify,
+ GenericEvent
};
>>ASSERTION Good A
A call to xname
diff --git a/xts5/src/lib/XInput.c b/xts5/src/lib/XInput.c
index 04169b79..35c3c95e 100644
--- a/xts5/src/lib/XInput.c
+++ b/xts5/src/lib/XInput.c
@@ -104,7 +104,7 @@ int NumKeys,
ButtonMapLength,
nclass,
nevent,
- event_types[32],
+ event_types[LASTEvent - 2], /* 0 and 1 are reply/error */
MinKeyCode,
MaxKeyCode,
Feedback_Class,