diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2007-10-26 20:12:19 +0200 |
---|---|---|
committer | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2007-10-26 20:12:19 +0200 |
commit | 253ea9de2321bccede3f0d74ee6a6f6b403e80ae (patch) | |
tree | d909a90d635a506ba6fca99ac075a4bcebcdf866 /src | |
parent | 38ba390f775e2f6001c8887328c5b925f623308a (diff) |
acecad: don't crash when xf86IsCorePointer is not defined
Diffstat (limited to 'src')
-rw-r--r-- | src/acecad.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/acecad.c b/src/acecad.c index 9b14e48..398024f 100644 --- a/src/acecad.c +++ b/src/acecad.c @@ -722,13 +722,15 @@ ReadInput (LocalDevicePtr local) { int x, y, z; int prox, buttons; - int is_core_pointer, is_absolute; + int is_core_pointer = 1, is_absolute; AceCadPrivatePtr priv = (AceCadPrivatePtr) (local->private); /*xf86Msg(X_INFO, "ACECAD Tablet Read Input\n");*/ is_absolute = (priv->flags & ABSOLUTE_FLAG); +#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0 is_core_pointer = xf86IsCorePointer(local->dev); +#endif /* * set blocking to -1 on the first call because we know there is data to @@ -829,7 +831,10 @@ USBReadInput (LocalDevicePtr local) int z = priv->acecadOldZ; int prox = priv->acecadOldProximity; int buttons = priv->acecadOldButtons; - int is_core_pointer = xf86IsCorePointer(local->dev); + int is_core_pointer = 1; +#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0 + is_core_pointer = xf86IsCorePointer(local->dev); +#endif /* Is autodev active? */ int autodev = priv->flags & AUTODEV_FLAG; /* Was the device available last time we checked? */ |