summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2010-10-01 01:44:21 -0400
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2010-10-01 09:33:14 +0300
commitee3c2bef131ff1d6723b66d5cec3c8738954b407 (patch)
treeb34a501c990b2a0c6dfe146ea0eedf86f6e64b6e /include
parent755124d0e8458460c59de12dcc0f4a5703a31028 (diff)
mtd-utils: dont redefine MIN()
Some C library headers will define MIN(), so add an #ifndef check. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'include')
-rw-r--r--include/common.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/common.h b/include/common.h
index 6684a73..25abc0c 100644
--- a/include/common.h
+++ b/include/common.h
@@ -33,7 +33,9 @@
extern "C" {
#endif
+#ifndef MIN /* some C lib headers define this for us */
#define MIN(a ,b) ((a) < (b) ? (a) : (b))
+#endif
#define min(a, b) MIN(a, b) /* glue for linux kernel source */
#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0]))