From 98cd97532832262c3e2183347f828f72df3ff48c Mon Sep 17 00:00:00 2001 From: Aaron Culliney Date: Sun, 30 Mar 2014 10:39:45 -0700 Subject: [PATCH] ifndef MIN() & MAX() macros --- src/common.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/common.h b/src/common.h index 8755ded1..9c1b5786 100644 --- a/src/common.h +++ b/src/common.h @@ -64,6 +64,14 @@ #include "audio/mockingboard.h" #endif +#if !defined(MIN) +#define MIN(a,b) (((a) <= (b)) ? (a) : (b)) +#endif + +#if !defined(MAX) +#define MAX(a,b) (((a) >= (b)) ? (a) : (b)) +#endif + #ifndef NDEBUG # if defined(__GNUC__) # pragma GCC diagnostic push