[PATCH 2/2] AllocDevicePair: Ensure XKB privates are initialised
Daniel Stone
daniel at fooishbar.org
Tue Jul 10 01:10:22 PDT 2012
Since we call directly into XKB and may be doing so before the extension
has been initialised, make sure its privates are set up first. XTest
had a hack to do this itself, but seems cleaner to just make sure we do
it in AllocDevicePair.
Signed-off-by: Daniel Stone <daniel at fooishbar.org>
---
dix/devices.c | 2 ++
test/xtest.c | 2 --
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dix/devices.c b/dix/devices.c
index 839de35..6a51d45 100644
--- a/dix/devices.c
+++ b/dix/devices.c
@@ -2672,6 +2672,8 @@ AllocDevicePair(ClientPtr client, const char *name,
*ptr = *keybd = NULL;
+ XkbInitPrivates();
+
pointer = AddInputDevice(client, ptr_proc, TRUE);
if (!pointer)
diff --git a/test/xtest.c b/test/xtest.c
index 99e2185..402d9ce 100644
--- a/test/xtest.c
+++ b/test/xtest.c
@@ -76,8 +76,6 @@ xtest_init_devices(void)
InitAtoms();
SyncExtensionInit();
- XkbInitPrivates();
-
/* this also inits the xtest devices */
InitCoreDevices();
--
1.7.10.4
More information about the xorg-devel
mailing list