From 8f2aaff6d7c73de94619898a3fcefc64af9bfbae Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Wed, 25 Jun 2014 16:17:52 +0400 Subject: [PATCH] fixed compile warnings on Windows --- modules/objdetect/src/detection_based_tracker.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/objdetect/src/detection_based_tracker.cpp b/modules/objdetect/src/detection_based_tracker.cpp index 211365a..f4dd2b3 100644 --- a/modules/objdetect/src/detection_based_tracker.cpp +++ b/modules/objdetect/src/detection_based_tracker.cpp @@ -79,10 +79,10 @@ #include -#define LOGD0(_str, ...) do{printf(_str , ## __VA_ARGS__); printf("\n");fflush(stdout);} while(0) -#define LOGI0(_str, ...) do{printf(_str , ## __VA_ARGS__); printf("\n");fflush(stdout);} while(0) -#define LOGW0(_str, ...) do{printf(_str , ## __VA_ARGS__); printf("\n");fflush(stdout);} while(0) -#define LOGE0(_str, ...) do{printf(_str , ## __VA_ARGS__); printf("\n");fflush(stdout);} while(0) +#define LOGD0(_str, ...) (printf(_str , ## __VA_ARGS__), printf("\n"), fflush(stdout)) +#define LOGI0(_str, ...) (printf(_str , ## __VA_ARGS__), printf("\n"), fflush(stdout)) +#define LOGW0(_str, ...) (printf(_str , ## __VA_ARGS__), printf("\n"), fflush(stdout)) +#define LOGE0(_str, ...) (printf(_str , ## __VA_ARGS__), printf("\n"), fflush(stdout)) #endif #if DEBUGLOGS @@ -91,10 +91,10 @@ #define LOGW(_str, ...) LOGW0(_str , ## __VA_ARGS__) #define LOGE(_str, ...) LOGE0(_str , ## __VA_ARGS__) #else -#define LOGD(...) do{} while(0) -#define LOGI(...) do{} while(0) -#define LOGW(...) do{} while(0) -#define LOGE(...) do{} while(0) +#define LOGD(...) +#define LOGI(...) +#define LOGW(...) +#define LOGE(...) #endif -- 2.7.4