From d1ca951cc4f3392aeec2817e97fb9ade2c1b7881 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Tue, 18 Mar 2008 11:49:02 +0000 Subject: [PATCH] gallium: Convenience debug_warning function. --- src/gallium/include/pipe/p_debug.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/gallium/include/pipe/p_debug.h b/src/gallium/include/pipe/p_debug.h index f971ad3adc0..f3dfa062161 100644 --- a/src/gallium/include/pipe/p_debug.h +++ b/src/gallium/include/pipe/p_debug.h @@ -158,6 +158,16 @@ void debug_mask_vprintf(uint32_t uuid, const char *format, va_list ap); + +#ifdef DEBUG +#define debug_warning(__msg) \ + debug_printf("%s:%i:warning: %s\n", __FILE__, __LINE__, (__msg)) +#else +#define debug_warning(__msg) \ + ((void)0) +#endif + + #ifdef __cplusplus } #endif -- 2.30.2