From 6fe5fde2922405176fbe9315971ab818193af0e0 Mon Sep 17 00:00:00 2001 From: Laine Stump Date: Tue, 19 Jul 2011 22:08:15 -0400 Subject: [PATCH] util: define MAX If util.h is going to have a MIN, it may as well also have MAX. --- src/util/util.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/util/util.h b/src/util/util.h index e8197be0d9..af8b15d8db 100644 --- a/src/util/util.h +++ b/src/util/util.h @@ -35,6 +35,9 @@ # ifndef MIN # define MIN(a, b) ((a) < (b) ? (a) : (b)) # endif +# ifndef MAX +# define MAX(a, b) ((a) > (b) ? (a) : (b)) +# endif ssize_t saferead(int fd, void *buf, size_t count) ATTRIBUTE_RETURN_CHECK; ssize_t safewrite(int fd, const void *buf, size_t count)