aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/lib.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/lib.h b/lib/lib.h
index 5d2bb4df..effba9b4 100644
--- a/lib/lib.h
+++ b/lib/lib.h
@@ -341,5 +341,8 @@ pid_t __attribute__((returns_twice)) xvforkwrap(pid_t pid);
// Wrapper that discards true/false "did it exit" value.
#define NOEXIT(x) WOULD_EXIT(_noexit_res, x)
+#define minof(a, b) ({typeof(a) aa = (a); typeof(b) bb = (b); aa<bb ? aa : bb;})
+#define maxof(a, b) ({typeof(a) aa = (a); typeof(b) bb = (b); aa>bb ? aa : bb;})
+
// Functions in need of further review/cleanup
#include "lib/pending.h"