mirror of
https://github.com/X11Libre/xf86-input-synaptics.git
synced 2026-04-14 11:54:16 +00:00
Close device if DeviceOnHook fails
Signed-off-by: Keith Packard <keithp@keithp.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
committed by
Peter Hutterer
parent
402cc87257
commit
22fe8bdc66
@@ -972,8 +972,10 @@ DeviceOn(DeviceIntPtr dev)
|
||||
}
|
||||
|
||||
if (priv->proto_ops->DeviceOnHook &&
|
||||
!priv->proto_ops->DeviceOnHook(pInfo, &priv->synpara))
|
||||
!priv->proto_ops->DeviceOnHook(pInfo, &priv->synpara)) {
|
||||
xf86CloseSerial(pInfo->fd);
|
||||
return !Success;
|
||||
}
|
||||
|
||||
priv->comm.buffer = XisbNew(pInfo->fd, INPUT_BUFFER_SIZE);
|
||||
if (!priv->comm.buffer) {
|
||||
|
||||
Reference in New Issue
Block a user