From cfc678be72a9d93c6d7511d585cfcfd75e63bb11 Mon Sep 17 00:00:00 2001 From: Gene Cumm Date: Fri, 16 Aug 2013 12:54:39 -0400 Subject: [PATCH] com32: Define ddprintf() macro Duplicating Debug Printf; Certain warning/error printf() statements are not visible if they occur before ldlinux.c32 is loaded Signed-off-by: Gene Cumm --- com32/include/dprintf.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/com32/include/dprintf.h b/com32/include/dprintf.h index 51d5c61..1b53969 100644 --- a/com32/include/dprintf.h +++ b/com32/include/dprintf.h @@ -18,9 +18,11 @@ # ifdef DEBUG_STDIO # define dprintf printf # define vdprintf vprintf +# define ddprintf dprintf # else void dprintf(const char *, ...); void vdprintf(const char *, va_list); +# define ddprintf(...) { printf(__VA_ARGS__); dprintf(__VA_ARGS__); } # endif #else @@ -31,6 +33,7 @@ void vdprintf(const char *, va_list); #define vdprintf(fmt, ap) \ if (syslinux_debug_enabled) \ vprintf(fmt, ap) +#define ddprintf printf #endif /* DEBUG */ -- 2.7.4