From df1704365e700d3cf1d36a241bdfc479159a8df7 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Thu, 10 May 2012 15:33:15 +1000 Subject: [PATCH] dix: free the sprite when disabling the device Disabled devices don't need sprites (they can't send events anyway) and the device init process is currently geared to check for whether sprite is present to check if the device should be paired/attached. Signed-off-by: Peter Hutterer Reviewed-by: Chase Douglas --- dix/devices.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dix/devices.c b/dix/devices.c index a280dee28..f134f31f9 100644 --- a/dix/devices.c +++ b/dix/devices.c @@ -465,6 +465,8 @@ DisableDevice(DeviceIntPtr dev, BOOL sendevent) (void) (*dev->deviceProc) (dev, DEVICE_OFF); dev->enabled = FALSE; + FreeSprite(dev); + /* now that the device is disabled, we can reset the signal handler's * last.slave */ OsBlockSignals();