summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@redhat.com>2008-11-26 15:01:57 +1000
committerPeter Hutterer <peter.hutterer@redhat.com>2008-12-03 16:36:59 +1000
commit2bf6e29b40f0da2bc417964fd2bd819306e5d3ed (patch)
tree20f337aea797245a8d4ea989800e4a350c8ba243 /src
parent2bd24649ecbae08b7bd4dacd67d141ae665f8db7 (diff)
Finalize MB emu (and wakeup handlers) before closing the fd.
Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
Diffstat (limited to 'src')
-rw-r--r--src/evdev.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/evdev.c b/src/evdev.c
index 275d6bc..7b06c91 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -1176,6 +1176,8 @@ EvdevProc(DeviceIntPtr device, int what)
return EvdevOn(device);
case DEVICE_OFF:
+ if (pEvdev->flags & EVDEV_INITIALIZED)
+ EvdevMBEmuFinalize(pInfo);
if (pInfo->fd != -1)
{
if (pEvdev->grabDevice && ioctl(pInfo->fd, EVIOCGRAB, (void *)0))