Message ID | 1291017722-23985-2-git-send-email-computersforpeace@gmail.com |
---|---|
State | Accepted |
Commit | 3941e9fd08f1d03a52f6584b70077ff0ac866696 |
Headers | show |
diff --git a/include/common.h b/include/common.h index 25abc0c..eb8d5fc 100644 --- a/include/common.h +++ b/include/common.h @@ -34,7 +34,10 @@ extern "C" { #endif #ifndef MIN /* some C lib headers define this for us */ -#define MIN(a ,b) ((a) < (b) ? (a) : (b)) +#define MIN(a, b) ((a) < (b) ? (a) : (b)) +#endif +#ifndef MAX +#define MAX(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]))
Add MAX() macro to common.h, to be used in future patches. Also a style change in comma location on MIN(). Signed-off-by: Brian Norris <computersforpeace@gmail.com> --- include/common.h | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)