From bc26665661565918af484ccd17caad951010df60 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Sun, 6 Jun 2010 20:45:53 -0700 Subject: Initialize private keys in test suite Make sure all of the private keys used by the test code are initialized before being used. Signed-off-by: Keith Packard Tested-by: Robert Hooker --- xkb/xkb.c | 2 +- xkb/xkbActions.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'xkb') diff --git a/xkb/xkb.c b/xkb/xkb.c index 04a137fe6..cbb46c62f 100644 --- a/xkb/xkb.c +++ b/xkb/xkb.c @@ -6707,7 +6707,7 @@ XkbExtensionInit(void) if (!RT_XKBCLIENT) return; - if (!dixRegisterPrivateKey(&xkbDevicePrivateKeyRec, PRIVATE_DEVICE, 0)) + if (!XkbInitPrivates()) return; if ((extEntry = AddExtension(XkbName, XkbNumberEvents, XkbNumberErrors, diff --git a/xkb/xkbActions.c b/xkb/xkbActions.c index afc44ac44..c5030d04d 100644 --- a/xkb/xkbActions.c +++ b/xkb/xkbActions.c @@ -63,6 +63,11 @@ xkbUnwrapProc(DeviceIntPtr device, DeviceHandleProc proc, backupproc,xkbUnwrapProc); } +Bool +XkbInitPrivates(void) +{ + return dixRegisterPrivateKey(&xkbDevicePrivateKeyRec, PRIVATE_DEVICE, 0); +} void XkbSetExtension(DeviceIntPtr device, ProcessInputProc proc) -- cgit v1.2.3