summaryrefslogtreecommitdiff
path: root/util.h
diff options
context:
space:
mode:
authorWilliam Casarin <jb55@jb55.com>2018-07-08 12:40:58 -0700
committerWilliam Casarin <jb55@jb55.com>2018-07-08 12:40:58 -0700
commit06203da5e3a7ff6fcc7b741607a9ddee6d979d5c (patch)
treee2ab4cd460ac87d2fb71bf79bf65b7b473765012 /util.h
parent83dbfd357c0a0d7798ad4ccf788476e56a5d5dbf (diff)
build stuff
Diffstat (limited to 'util.h')
-rw-r--r--util.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/util.h b/util.h
new file mode 100644
index 0000000..1654832
--- /dev/null
+++ b/util.h
@@ -0,0 +1,14 @@
+
+/* See LICENSE file for copyright and license details. */
+
+#ifndef CMDTREE_UTIL_H
+#define CMDTREE_UTIL_H
+
+#define MAX(A, B) ((A) > (B) ? (A) : (B))
+#define MIN(A, B) ((A) < (B) ? (A) : (B))
+#define BETWEEN(X, A, B) ((A) <= (X) && (X) <= (B))
+
+void die(const char *fmt, ...);
+void *ecalloc(size_t nmemb, size_t size);
+
+#endif /* CMDTREE_UTIL_H */