Xext: don't try to initialize XTEST device properties if they failed.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
744cdc8977
commit
e62549b8d6
|
@ -642,9 +642,6 @@ int AllocXTestDevice (ClientPtr client, char* name,
|
||||||
if ( retval == Success ){
|
if ( retval == Success ){
|
||||||
dixSetPrivate(&((*ptr)->devPrivates), XTestDevicePrivateKey, (void *)master_ptr->id);
|
dixSetPrivate(&((*ptr)->devPrivates), XTestDevicePrivateKey, (void *)master_ptr->id);
|
||||||
dixSetPrivate(&((*keybd)->devPrivates), XTestDevicePrivateKey, (void *)master_keybd->id);
|
dixSetPrivate(&((*keybd)->devPrivates), XTestDevicePrivateKey, (void *)master_keybd->id);
|
||||||
}
|
|
||||||
|
|
||||||
xfree( xtestname );
|
|
||||||
|
|
||||||
XIChangeDeviceProperty(*ptr, XIGetKnownProperty(XI_PROP_XTEST_DEVICE),
|
XIChangeDeviceProperty(*ptr, XIGetKnownProperty(XI_PROP_XTEST_DEVICE),
|
||||||
XA_INTEGER, 8, PropModeReplace, 1, &dummy,
|
XA_INTEGER, 8, PropModeReplace, 1, &dummy,
|
||||||
|
@ -656,6 +653,9 @@ int AllocXTestDevice (ClientPtr client, char* name,
|
||||||
FALSE);
|
FALSE);
|
||||||
XISetDevicePropertyDeletable(*keybd, XIGetKnownProperty(XI_PROP_XTEST_DEVICE), FALSE);
|
XISetDevicePropertyDeletable(*keybd, XIGetKnownProperty(XI_PROP_XTEST_DEVICE), FALSE);
|
||||||
XIRegisterPropertyHandler(*keybd, DeviceSetXTestProperty, NULL, NULL);
|
XIRegisterPropertyHandler(*keybd, DeviceSetXTestProperty, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
xfree( xtestname );
|
||||||
|
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user