[PATCH] common: fix macro WARN

Christoph Fritz chf at fritzc.com
Mon May 12 08:57:32 PDT 2014


Signed-off-by: Christoph Fritz <chf.fritz at googlemail.com>
---
 include/common.h |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/include/common.h b/include/common.h
index bfd3ce8..e7ab5fe 100644
--- a/include/common.h
+++ b/include/common.h
@@ -72,10 +72,11 @@
 #ifndef WARN
 #define WARN(condition, format...) ({					\
 	int __ret_warn_on = !!(condition);				\
-	if (unlikely(__ret_warn_on))					\
+	if (unlikely(__ret_warn_on)) {					\
 		__WARN();						\
 		puts("WARNING: ");					\
 		printf(format);						\
+	}								\
 	unlikely(__ret_warn_on);					\
 })
 #endif
-- 
1.7.10.4





More information about the barebox mailing list