diff options
author | Peter Harris <pharris@opentext.com> | 2013-05-30 18:44:22 -0400 |
---|---|---|
committer | Peter Harris <pharris@opentext.com> | 2013-05-30 18:44:22 -0400 |
commit | 2c0b8ea68cbfa35883e0d41af4a3359e8f688601 (patch) | |
tree | 5a98dcaf4b2aef0b24b71cc7bd075bd03212081e | |
parent | d3e7db3fb3c2bd39e30bc1d4ccdf81a00b556c31 (diff) |
XI: Fix random failures on LP64 platforms
It turns out that XID is a 'long' for historical reasons, but the XInput
error macros expect a pointer-to-int.
Signed-off-by: Peter Harris <pharris@opentext.com>
28 files changed, 42 insertions, 41 deletions
diff --git a/xts5/XI/AllowDeviceEvents.m b/xts5/XI/AllowDeviceEvents.m index 90e26a27..ecde6ae2 100644 --- a/xts5/XI/AllowDeviceEvents.m +++ b/xts5/XI/AllowDeviceEvents.m @@ -1338,7 +1338,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ret; if (!grabstartup()) diff --git a/xts5/XI/ChangeDeviceControl.m b/xts5/XI/ChangeDeviceControl.m index 92f56d67..4ce7ae79 100644 --- a/xts5/XI/ChangeDeviceControl.m +++ b/xts5/XI/ChangeDeviceControl.m @@ -465,7 +465,7 @@ If an invalid device is specified, a BadDevice error will result. Do a ChangeDeviceControl request, specifying an invalid device. >>CODE baddevice XDevice bogus; -XID baddevice; +int baddevice; int ximajor, first, err, ret, val; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/ChangeFeedbackControl.m b/xts5/XI/ChangeFeedbackControl.m index febb9342..e240e677 100644 --- a/xts5/XI/ChangeFeedbackControl.m +++ b/xts5/XI/ChangeFeedbackControl.m @@ -590,7 +590,7 @@ If an invalid device is specified, a BadDevice error will result. Do a ChangeFeedbackControl, specifying an invalid device. >>CODE baddevice XDevice bogus; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) { diff --git a/xts5/XI/ChangeKeyboardDevice.m b/xts5/XI/ChangeKeyboardDevice.m index 678db9e2..b0b6b16d 100644 --- a/xts5/XI/ChangeKeyboardDevice.m +++ b/xts5/XI/ChangeKeyboardDevice.m @@ -351,7 +351,7 @@ Change the keyboard to a new device. Verify that all input device extension requests that require a Device pointer fail with a BadDevice error, when the new keyboard is specified. >>CODE -XID baddevice; +int baddevice; int devicekeypress; XDeviceInfo *list; int i, ndevices, revert, nfeed, mask, ksyms_per; @@ -690,7 +690,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/ChangePointerDevice.m b/xts5/XI/ChangePointerDevice.m index 0c18a588..d203f6e3 100644 --- a/xts5/XI/ChangePointerDevice.m +++ b/xts5/XI/ChangePointerDevice.m @@ -358,7 +358,7 @@ Change the pointer to a new device. Verify that all input device extension requests that require a Device pointer fail with a BadDevice error, when the new pointer is specified. >>CODE -XID baddevice; +int baddevice; int devicemotionnotify; XDeviceInfo *list; int i, ndevices, revert, nfeed, mask, ksyms_per, savid; @@ -722,7 +722,7 @@ When an invalid device is specified, a BadDevice error will result. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/CloseDevice.m b/xts5/XI/CloseDevice.m index 1ab0273c..c1bc64c4 100644 --- a/xts5/XI/CloseDevice.m +++ b/xts5/XI/CloseDevice.m @@ -400,7 +400,7 @@ Call xname to close a device. Call other input device extension requests. Verify a BadDevice error occurs. >>CODE -XID baddevice; +int baddevice; int devicekeypress; XDeviceInfo *list; int ret, i, j, ndevices, revert, nfeed, mask, ksyms_per; @@ -813,7 +813,7 @@ is specified. >>STRATEGY Make the call with an invalid device. >>CODE baddevice -XID baddevice; +int baddevice; int ret; if (!Setup_Extension_DeviceInfo(KeyMask)) diff --git a/xts5/XI/DeviceBell.m b/xts5/XI/DeviceBell.m index 95d2df3f..a4bd5804 100644 --- a/xts5/XI/DeviceBell.m +++ b/xts5/XI/DeviceBell.m @@ -224,7 +224,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/GetDeviceMotionEvents.m b/xts5/XI/GetDeviceMotionEvents.m index b9632962..29e20e34 100644 --- a/xts5/XI/GetDeviceMotionEvents.m +++ b/xts5/XI/GetDeviceMotionEvents.m @@ -448,7 +448,7 @@ results. Specify an invalid device. Verify that a BadDevice error results. >>CODE baddevice -XID baddevice; +int baddevice; XDevice nodevice; XDeviceTimeCoord *tc; int ximajor, first, err; diff --git a/xts5/XI/GetFeedbackControl.m b/xts5/XI/GetFeedbackControl.m index fd13075f..bc0097e2 100644 --- a/xts5/XI/GetFeedbackControl.m +++ b/xts5/XI/GetFeedbackControl.m @@ -139,7 +139,7 @@ XFeedbackState *state; A call to xname returns a BadDevice error if an invalid device is specified. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; XFeedbackState *state; int ximajor, first, err; diff --git a/xts5/XI/GrabDevice.m b/xts5/XI/GrabDevice.m index 7eae5d76..9f6bf171 100644 --- a/xts5/XI/GrabDevice.m +++ b/xts5/XI/GrabDevice.m @@ -260,7 +260,7 @@ Call xname, specifying event classes from another device. Verify that a BadClass error occurs. >>CODE badclass int ret; -XID badclass; +int badclass; int dkp; XEventClass dkpclass; @@ -679,7 +679,7 @@ a BadClass error will result. Verify that xname fails and returns BadValue. >>CODE badclass int ret; -XID badclass; +int badclass; XEventClass bogus[2]; if (!Setup_Extension_DeviceInfo(AnyMask)) @@ -795,7 +795,7 @@ Verify that xname fails and returns BadDevice. >>CODE baddevice int ret; XDevice bogus; -XID baddevice; +int baddevice; if (!Setup_Extension_DeviceInfo(AnyMask)) { diff --git a/xts5/XI/GrabDeviceButton.m b/xts5/XI/GrabDeviceButton.m index e95a77b9..511122c6 100644 --- a/xts5/XI/GrabDeviceButton.m +++ b/xts5/XI/GrabDeviceButton.m @@ -1079,7 +1079,7 @@ a BadDevice error will result. Specify an invalid device. >>CODE baddevice XDevice bogus; -XID baddevice; +int baddevice; if (!Setup_Extension_DeviceInfo(BtnMask)) { @@ -1106,7 +1106,7 @@ a BadDevice error will result. Specify an invalid modifier device. >>CODE baddevice XDevice bogus; -XID baddevice; +int baddevice; if (!Setup_Extension_DeviceInfo(BtnMask)) { @@ -1133,7 +1133,7 @@ a BadClass error will result. Specify an invalid event class. >>CODE badclass XEventClass eclass = -1; -XID badclass; +int badclass; if (!Setup_Extension_DeviceInfo(ModMask | BtnMask)) { diff --git a/xts5/XI/GrabDeviceKey.m b/xts5/XI/GrabDeviceKey.m index 2dd5bcf1..a3eeada1 100644 --- a/xts5/XI/GrabDeviceKey.m +++ b/xts5/XI/GrabDeviceKey.m @@ -1063,7 +1063,7 @@ BadMatch error results. When an invalid modifier_device is specified in an xname protocol request, a BadValue error results. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; if (!Setup_Extension_DeviceInfo(KeyMask)) @@ -1088,7 +1088,7 @@ XDevice bogus; When an invalid device is specified in an xname protocol request, a BadValue error results. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; if (!Setup_Extension_DeviceInfo(KeyMask)) @@ -1116,7 +1116,7 @@ BadValue error results. Specify an invalid event class. >>CODE badclass XEventClass eclass = -1; -XID badclass; +int badclass; if (!Setup_Extension_DeviceInfo(KeyMask)) { diff --git a/xts5/XI/OpenDevice.m b/xts5/XI/OpenDevice.m index 595e01b4..66d19aca 100644 --- a/xts5/XI/OpenDevice.m +++ b/xts5/XI/OpenDevice.m @@ -150,7 +150,7 @@ A call to xname with an invalid deviceid returns a BadDevice error. Call xname. >>CODE baddevice XDevice *dev; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) @@ -173,7 +173,7 @@ returns a BadDevice error. Call xname. >>CODE baddevice int i, ndevs; -XID baddevice; +int baddevice; XDeviceInfo *list; XDevice *ret; diff --git a/xts5/XI/SendExtensionEvent.m b/xts5/XI/SendExtensionEvent.m index 01f448dc..2a13d8ef 100644 --- a/xts5/XI/SendExtensionEvent.m +++ b/xts5/XI/SendExtensionEvent.m @@ -2282,7 +2282,7 @@ Specify a bad device. Initialise the event structure for the call. Verify that a baddevice error occurs. >>CODE baddevice -XID baddevice; +int baddevice; int dbp; XEventClass dbpc; XDevice bogus; @@ -2329,7 +2329,7 @@ Specify a bad event class; Initialise the event structure for the call. Verify that a badclass error occurs. >>CODE badclass -XID badclass; +int badclass; int dbp; XEventClass bogus=-1, dbpc; int return_value; diff --git a/xts5/XI/SetDeviceButtonMapping.m b/xts5/XI/SetDeviceButtonMapping.m index 54b03ad7..62108ec5 100644 --- a/xts5/XI/SetDeviceButtonMapping.m +++ b/xts5/XI/SetDeviceButtonMapping.m @@ -111,7 +111,7 @@ int nmap = 255; */ #define MAPSIZE 256 static unsigned char Map[MAPSIZE]; -static XID baddevice; +static int baddevice; static int nbtns; extern ExtDeviceInfo Devs; diff --git a/xts5/XI/SetDeviceMode.m b/xts5/XI/SetDeviceMode.m index 8139cbfa..04305973 100644 --- a/xts5/XI/SetDeviceMode.m +++ b/xts5/XI/SetDeviceMode.m @@ -224,7 +224,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) { diff --git a/xts5/XI/SetDeviceModifierMapping.m b/xts5/XI/SetDeviceModifierMapping.m index fad3d267..22f179a1 100644 --- a/xts5/XI/SetDeviceModifierMapping.m +++ b/xts5/XI/SetDeviceModifierMapping.m @@ -465,7 +465,7 @@ If an invalid device is specified, a BadDevice error occurs. Specifiy an invalid device. >>CODE baddevice int ret; -XID baddevice; +int baddevice; XDevice bogus; int ximajor, first, err; diff --git a/xts5/XI/SetDeviceValuators.m b/xts5/XI/SetDeviceValuators.m index 54b4ccdf..94bae1c8 100644 --- a/xts5/XI/SetDeviceValuators.m +++ b/xts5/XI/SetDeviceValuators.m @@ -380,7 +380,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) { diff --git a/xts5/XI/UngrabDeviceButton.m b/xts5/XI/UngrabDeviceButton.m index 64c214bd..203b6fca 100644 --- a/xts5/XI/UngrabDeviceButton.m +++ b/xts5/XI/UngrabDeviceButton.m @@ -648,7 +648,8 @@ BadMatch error. A call to xname specifying an invalid device results in a BadDevice error. >>CODE baddevice -XID baddevice, savedevice; +int baddevice; +XID savedevice; if (!Setup_Extension_DeviceInfo(BtnMask)) { @@ -675,7 +676,7 @@ XID baddevice, savedevice; A call to xname specifying an invalid modifier device results in a BadDevice error. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; if (!Setup_Extension_DeviceInfo(BtnMask)) diff --git a/xts5/XI/UngrabDeviceKey.m b/xts5/XI/UngrabDeviceKey.m index 1b577f82..85927c47 100644 --- a/xts5/XI/UngrabDeviceKey.m +++ b/xts5/XI/UngrabDeviceKey.m @@ -656,7 +656,7 @@ BadMatch error. A call to xname specifying an invalid modifier device results in a BadDevice error. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; if (!Setup_Extension_DeviceInfo(KeyMask)) @@ -680,7 +680,7 @@ XDevice bogus; A call to xname specifying an invalid grab device results in a BadDevice error. >>CODE baddevice -XID baddevice; +int baddevice; XDevice bogus; if (!Setup_Extension_DeviceInfo(KeyMask)) diff --git a/xts5/XI/XGetDeviceControl.m b/xts5/XI/XGetDeviceControl.m index 403447e9..ff1fdc0f 100644 --- a/xts5/XI/XGetDeviceControl.m +++ b/xts5/XI/XGetDeviceControl.m @@ -171,7 +171,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/XGetDeviceFocus.m b/xts5/XI/XGetDeviceFocus.m index 5afd4828..e0887472 100644 --- a/xts5/XI/XGetDeviceFocus.m +++ b/xts5/XI/XGetDeviceFocus.m @@ -107,7 +107,7 @@ Time *time1 = &focus_time; Window fwin; int revert; Time focus_time; -XID baddevice; +int baddevice; extern ExtDeviceInfo Devs; >>ASSERTION Good B 3 diff --git a/xts5/XI/XGetDeviceKeyMapping.m b/xts5/XI/XGetDeviceKeyMapping.m index 69dd2532..3b621cd7 100644 --- a/xts5/XI/XGetDeviceKeyMapping.m +++ b/xts5/XI/XGetDeviceKeyMapping.m @@ -412,7 +412,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/XGetDeviceModifierMapping.m b/xts5/XI/XGetDeviceModifierMapping.m index a94a6289..fef3bb6c 100644 --- a/xts5/XI/XGetDeviceModifierMapping.m +++ b/xts5/XI/XGetDeviceModifierMapping.m @@ -301,7 +301,7 @@ If an invalid device is specified, a BadDevice error occurs. Specifiy an invalid device. >>CODE baddevice XModifierKeymap *ret; -XID baddevice; +int baddevice; XDevice bogus; int ximajor, first, err; diff --git a/xts5/XI/XQueryDeviceState.m b/xts5/XI/XQueryDeviceState.m index 003477e5..4ac6e924 100644 --- a/xts5/XI/XQueryDeviceState.m +++ b/xts5/XI/XQueryDeviceState.m @@ -593,7 +593,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) diff --git a/xts5/XI/XSelectExtensionEvent.m b/xts5/XI/XSelectExtensionEvent.m index 1b361e1c..253d54ec 100644 --- a/xts5/XI/XSelectExtensionEvent.m +++ b/xts5/XI/XSelectExtensionEvent.m @@ -1382,7 +1382,7 @@ XEventClass dbpgclass; A call to xname specifying an invalid eventclass results in a BadClass error. >>CODE badclass -XID badclass; +int badclass; XEventClass bogus; if (!Setup_Extension_DeviceInfo(BtnMask)) diff --git a/xts5/XI/XSetDeviceFocus.m b/xts5/XI/XSetDeviceFocus.m index 0fafc4fa..e0c39200 100644 --- a/xts5/XI/XSetDeviceFocus.m +++ b/xts5/XI/XSetDeviceFocus.m @@ -104,7 +104,7 @@ Window focus = PointerRoot; int revert_to = RevertToPointerRoot; int time1 = CurrentTime; >>EXTERN -XID baddevice; +int baddevice; extern ExtDeviceInfo Devs; extern int MinKeyCode; diff --git a/xts5/XI/XUngrabDevice.m b/xts5/XI/XUngrabDevice.m index 864adea7..2f3b7f8f 100644 --- a/xts5/XI/XUngrabDevice.m +++ b/xts5/XI/XUngrabDevice.m @@ -377,7 +377,7 @@ is specified. Make the call with an invalid device. >>CODE baddevice XDevice nodevice; -XID baddevice; +int baddevice; int ximajor, first, err; if (!XQueryExtension (display, INAME, &ximajor, &first, &err)) |