summaryrefslogtreecommitdiff
path: root/test/xi2/protocol-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/xi2/protocol-common.c')
-rw-r--r--test/xi2/protocol-common.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/test/xi2/protocol-common.c b/test/xi2/protocol-common.c
index 9a429e49f..64a5777d0 100644
--- a/test/xi2/protocol-common.c
+++ b/test/xi2/protocol-common.c
@@ -137,6 +137,7 @@ init_devices(void)
{
ClientRec client;
struct devices local_devices;
+ int ret;
client = init_client(0, NULL);
@@ -145,15 +146,20 @@ init_devices(void)
inputInfo.pointer = local_devices.vcp;
inputInfo.keyboard = local_devices.vck;
- ActivateDevice(local_devices.vcp, FALSE);
- ActivateDevice(local_devices.vck, FALSE);
+ ret = ActivateDevice(local_devices.vcp, FALSE);
+ assert(ret == Success);
+ /* This may fail if xkbcomp fails or xkb-config is not found. */
+ ret = ActivateDevice(local_devices.vck, FALSE);
+ assert(ret == Success);
EnableDevice(local_devices.vcp, FALSE);
EnableDevice(local_devices.vck, FALSE);
AllocDevicePair(&client, "", &local_devices.mouse, &local_devices.kbd,
TestPointerProc, CoreKeyboardProc, FALSE);
- ActivateDevice(local_devices.mouse, FALSE);
- ActivateDevice(local_devices.kbd, FALSE);
+ ret = ActivateDevice(local_devices.mouse, FALSE);
+ assert(ret == Success);
+ ret = ActivateDevice(local_devices.kbd, FALSE);
+ assert(ret == Success);
EnableDevice(local_devices.mouse, FALSE);
EnableDevice(local_devices.kbd, FALSE);