[PATCH libinput 12/20] Add a log_bug macro
Hans de Goede
hdegoede at redhat.com
Tue Apr 15 05:28:09 PDT 2014
For logging when things happen which should not happen. We may want to do
something more fancy in the future but for now this suffices.
Modelled after log_bug in libevdev.
Signed-off-by: Hans de Goede <hdegoede at redhat.com>
Acked-by: Peter Hutterer <peter.hutterer at who-t.net>
---
src/libinput-private.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/libinput-private.h b/src/libinput-private.h
index 21627b0..f778f6e 100644
--- a/src/libinput-private.h
+++ b/src/libinput-private.h
@@ -80,6 +80,7 @@ struct libinput_source;
#define log_debug(...) log_msg(LIBINPUT_LOG_PRIORITY_DEBUG, __VA_ARGS__)
#define log_info(...) log_msg(LIBINPUT_LOG_PRIORITY_INFO, __VA_ARGS__)
#define log_error(...) log_msg(LIBINPUT_LOG_PRIORITY_ERROR, __VA_ARGS__)
+#define log_bug(...) log_msg(LIBINPUT_LOG_PRIORITY_ERROR, "BUG: "__VA_ARGS__)
void
log_msg(enum libinput_log_priority priority, const char *format, ...);
--
1.9.0
More information about the wayland-devel
mailing list