From 3fce95bcfa9e619d841a36bd8fc9475e244a969b Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Fri, 21 Sep 2012 15:42:16 +0100 Subject: [PATCH 05/21] WARNING, etc. macros: add Signed-off-by: Simon McVittie Bug: https://bugs.freedesktop.org/show_bug.cgi?id=55391 --- src/mcd-debug.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/mcd-debug.h b/src/mcd-debug.h index 66fdafc..f9bd022 100644 --- a/src/mcd-debug.h +++ b/src/mcd-debug.h @@ -47,6 +47,15 @@ G_BEGIN_DECLS #endif /* ENABLE_DEBUG */ +#define MESSAGE(format, ...) \ + g_message ("%s: " format, G_STRFUNC, ##__VA_ARGS__) +#define WARNING(format, ...) \ + g_warning ("%s: " format, G_STRFUNC, ##__VA_ARGS__) +#define CRITICAL(format, ...) \ + g_critical ("%s: " format, G_STRFUNC, ##__VA_ARGS__) +#define ERROR(format, ...) \ + g_error ("%s: " format, G_STRFUNC, ##__VA_ARGS__) + extern gint mcd_debug_level; void mcd_debug_init (void); -- 1.7.10.4