aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86/common/xf86Xinput.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xfree86/common/xf86Xinput.c')
-rw-r--r--xorg-server/hw/xfree86/common/xf86Xinput.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/xorg-server/hw/xfree86/common/xf86Xinput.c b/xorg-server/hw/xfree86/common/xf86Xinput.c
index 55cd49c1f..21921b2c3 100644
--- a/xorg-server/hw/xfree86/common/xf86Xinput.c
+++ b/xorg-server/hw/xfree86/common/xf86Xinput.c
@@ -622,7 +622,6 @@ MergeInputClasses(IDevPtr idev, InputAttributes *attrs)
mergedopts = xf86ReplaceStrOption(mergedopts, "driver", idev->driver);
}
idev->commonOptions = xf86optionListMerge(idev->commonOptions, mergedopts);
-
return Success;
}
@@ -822,6 +821,8 @@ NewInputDeviceRequest (InputOption *options, InputAttributes *attrs,
rval = MergeInputClasses(idev, attrs);
if (rval != Success)
goto unwind;
+
+ idev->attrs = DuplicateInputAttributes(attrs);
}
if (!idev->driver || !idev->identifier) {
@@ -853,7 +854,7 @@ unwind:
}
void
-DeleteInputDeviceRequest(DeviceIntPtr pDev)
+DeleteInputDeviceRequest(DeviceIntPtr pDev, int flags)
{
LocalDevicePtr pInfo = (LocalDevicePtr) pDev->public.devicePrivate;
InputDriverPtr drv = NULL;
@@ -873,9 +874,9 @@ DeleteInputDeviceRequest(DeviceIntPtr pDev)
if (!isMaster && pInfo != NULL)
{
if(drv->UnInit)
- drv->UnInit(drv, pInfo, 0);
+ drv->UnInit(drv, pInfo, flags);
else
- xf86DeleteInput(pInfo, 0);
+ xf86DeleteInput(pInfo, flags);
/* devices added through HAL aren't in the config layout */
it = xf86ConfigLayout.inputs;
@@ -1266,7 +1267,7 @@ xf86DisableDevice(DeviceIntPtr dev, Bool panic)
} else
{
SendDevicePresenceEvent(dev->id, DeviceUnrecoverable);
- DeleteInputDeviceRequest(dev);
+ DeleteInputDeviceRequest(dev, 0);
}
}