summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Hutterer <peter@cs.unisa.edu.au>2008-05-22 18:02:10 +0930
committerPeter Hutterer <peter@cs.unisa.edu.au>2008-05-22 18:08:32 +0930
commit74372fd0049676787904f1f9f80f836b97f5f60e (patch)
treeda0d7859c241c1c6fe6d4f04b9d24fa7291afa94
parent30e9a33f7d1972dcf1c29c7455b2cea4e5857913 (diff)
xfree86: suspend signals while removing a device.
Getting a keyboard event while halfway through freeing memory can be unpleasant.
-rw-r--r--hw/xfree86/common/xf86Xinput.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/xfree86/common/xf86Xinput.c b/hw/xfree86/common/xf86Xinput.c
index e53756fc2..996162402 100644
--- a/hw/xfree86/common/xf86Xinput.c
+++ b/hw/xfree86/common/xf86Xinput.c
@@ -475,6 +475,7 @@ DeleteInputDeviceRequest(DeviceIntPtr pDev)
drv = pInfo->drv;
idev = pInfo->conf_idev;
}
+ OsBlockSignals();
RemoveDevice(pDev);
if (pDev->isMaster)
@@ -484,6 +485,7 @@ DeleteInputDeviceRequest(DeviceIntPtr pDev)
drv->UnInit(drv, pInfo, 0);
else
xf86DeleteInput(pInfo, 0);
+ OsReleaseSignals();
/* devices added through HAL aren't in the config layout */
it = xf86ConfigLayout.inputs;