[Spice-devel] [PATCH 1/2] remove duplicated macro

Christophe Fergeau cfergeau at gmail.com
Fri Apr 1 09:19:11 PDT 2011


MIN() is already defined in spice-protocol/spice/macros.h
---
 server/tests/test_util.h |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/server/tests/test_util.h b/server/tests/test_util.h
index 5344a4f..c63f051 100644
--- a/server/tests/test_util.h
+++ b/server/tests/test_util.h
@@ -1,14 +1,16 @@
 #ifndef __TEST_UTIL_H__
 #define __TEST_UTIL_H__
 
+#ifndef TRUE
 #define TRUE 1
 #define FALSE 0
+#endif
 
+#ifndef ASSERT
 #define ASSERT(x) if (!(x)) {                               \
     printf("%s: ASSERT %s failed\n", __FUNCTION__, #x);     \
     abort();                                                \
 }
-
-#define MIN(a,b) ((a) > (b) ? (b) : (a))
+#endif
 
 #endif // __TEST_UTIL_H__
-- 
1.7.4.2



More information about the Spice-devel mailing list