[PATCH synaptics] Use LogMessageVerbSigSafe on ABI 18
Peter Hutterer
peter.hutterer at who-t.net
Thu May 24 21:22:07 PDT 2012
Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
src/eventcomm.c | 7 ++++---
src/synapticsstr.h | 4 ++++
test/fake-symbols.c | 8 ++++++++
3 files changed, 16 insertions(+), 3 deletions(-)
diff --git a/src/eventcomm.c b/src/eventcomm.c
index 6cfbcc7..57070c8 100644
--- a/src/eventcomm.c
+++ b/src/eventcomm.c
@@ -556,9 +556,10 @@ EventProcessTouchEvent(InputInfoPtr pInfo, struct SynapticsHwState *hw,
valuator_mask_copy(hw->mt_mask[slot_index],
proto_data->last_mt_vals[slot_index]);
else
- xf86IDrvMsg(pInfo, X_WARNING,
- "Attempted to copy values from out-of-range "
- "slot, touch events may be incorrect.\n");
+ LogMessageVerbSigSafe(X_WARNING, 0,
+ "%s: Attempted to copy values from out-of-range "
+ "slot, touch events may be incorrect.\n",
+ pInfo->name);
}
else if (hw->slot_state[slot_index] != SLOTSTATE_EMPTY) {
hw->slot_state[slot_index] = SLOTSTATE_CLOSE;
diff --git a/src/synapticsstr.h b/src/synapticsstr.h
index 384b7bb..79087a2 100644
--- a/src/synapticsstr.h
+++ b/src/synapticsstr.h
@@ -25,6 +25,10 @@
#include "synproto.h"
#include <xserver-properties.h>
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 18
+#define LogMessageVerbSigSafe xf86MsgVerb
+#endif
+
#ifdef DBG
#undef DBG
#endif
diff --git a/test/fake-symbols.c b/test/fake-symbols.c
index 173e1af..9e5a9ee 100644
--- a/test/fake-symbols.c
+++ b/test/fake-symbols.c
@@ -316,6 +316,14 @@ xf86IDrvMsg(InputInfoPtr dev, MessageType type, const char *format, ...)
return;
}
+struct log_param_t;
+_X_EXPORT void
+_LogMessageVerbSigSafe(MessageType type, int verb, const char *format,
+ const log_param_t *args, int num_args)
+{
+ return;
+}
+
_X_EXPORT void
xf86PostMotionEventP(DeviceIntPtr device,
int is_absolute, int first_valuator, int num_valuators,
--
1.7.10.1
More information about the xorg-devel
mailing list