diff options
Diffstat (limited to 'otherlibs/win32unix/windbug.h')
-rw-r--r-- | otherlibs/win32unix/windbug.h | 21 |
1 files changed, 5 insertions, 16 deletions
diff --git a/otherlibs/win32unix/windbug.h b/otherlibs/win32unix/windbug.h index 232bb1989..69cbd3b6e 100644 --- a/otherlibs/win32unix/windbug.h +++ b/otherlibs/win32unix/windbug.h @@ -13,17 +13,15 @@ /* $Id$ */ -/*#define DBUG*/ - -#ifdef DBUG +#ifdef DEBUG #include <stdio.h> #include <windows.h> -#define DBUG_PRINT(fmt, ...) \ +#define DEBUG_PRINT(fmt, ...) \ do \ { \ - if (dbug_test()) \ + if (debug_test()) \ { \ fprintf(stderr, "DBUG (pid:%d, tid: %d): ", GetCurrentProcessId(), GetCurrentThreadId()); \ fprintf(stderr, fmt, __VA_ARGS__); \ @@ -32,18 +30,9 @@ }; \ } while(0) -/* Initialize and cleanup dbug variable */ -void dbug_init (void); -void dbug_cleanup (void); - /* Test if we are in dbug mode */ -int dbug_test (void); - -#define DBUG_INIT dbug_init() -#define DBUG_CLEANUP dbug_cleanup() +int debug_test (void); #else -#define DBUG_PRINT(fmt, ...) -#define DBUG_INIT -#define DBUG_CLEANUP +#define DEBUG_PRINT(fmt, ...) #endif |