diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2012-05-21 14:07:41 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2012-05-31 14:56:48 +1000 |
commit | 0b644aec4015b5b0c41ad03fd3850e4708e7b080 (patch) | |
tree | 43b167698e7ec446e04337645648456500bc2a13 | |
parent | b3819411d9c61f1053d1ee6313979a06124a6f8c (diff) |
DeviceOn and friends return a status code, not a bool
No functional changes, just making things more obvious.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | src/synaptics-x11.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/synaptics-x11.c b/src/synaptics-x11.c index ff718a9..b7e204c 100644 --- a/src/synaptics-x11.c +++ b/src/synaptics-x11.c @@ -282,7 +282,7 @@ DeviceInitAcceleration(DeviceIntPtr dev) PropModeReplace, 1, &i, FALSE); } -static Bool +static int DeviceInit(DeviceIntPtr dev) { InputInfoPtr pInfo = dev->public.devicePrivate; @@ -374,7 +374,7 @@ DeviceInit(DeviceIntPtr dev) } -static Bool +static int DeviceOn(DeviceIntPtr dev) { InputInfoPtr pInfo = dev->public.devicePrivate; @@ -383,11 +383,11 @@ DeviceOn(DeviceIntPtr dev) pInfo->fd = xf86OpenSerial(pInfo->options); if (pInfo->fd == -1) { SynapticsMsg(priv, MSG_WARN, "cannot open input device\n"); - return !Success; + return BadAlloc; } if (!SynapticsEnableDevice(priv, pInfo->fd)) - return !Success; + return BadAlloc; xf86FlushInput(pInfo->fd); @@ -395,7 +395,7 @@ DeviceOn(DeviceIntPtr dev) if (!SynapticsQueryHardware(priv, pInfo->fd)) { xf86CloseSerial(pInfo->fd); pInfo->fd = -1; - return !Success; + return BadAlloc; } xf86AddEnabledDevice(pInfo); @@ -404,7 +404,7 @@ DeviceOn(DeviceIntPtr dev) return Success; } -static Bool +static int DeviceOff(DeviceIntPtr dev) { InputInfoPtr pInfo = dev->public.devicePrivate; @@ -426,7 +426,7 @@ DeviceOff(DeviceIntPtr dev) return rc; } -static Bool +static int DeviceClose(DeviceIntPtr dev) { Bool RetValue; @@ -445,7 +445,7 @@ DeviceClose(DeviceIntPtr dev) return RetValue; } -static Bool +static int DeviceControl(DeviceIntPtr dev, int mode) { Bool RetValue; |