X-Git-Url: https://git.danieliu.xyz/?p=dwm.git;a=blobdiff_plain;f=util.h;h=f633b5173ad2b5058d48574d5a18fe3f135c4193;hp=033700cadd75205410e46a6f57aa9d33f0ab1511;hb=HEAD;hpb=f21d46ea7def76221c4173f644eb2188ae9edbb1 diff --git a/util.h b/util.h index 033700c..f633b51 100644 --- a/util.h +++ b/util.h @@ -2,5 +2,7 @@ #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 *errstr, ...); +void die(const char *fmt, ...); +void *ecalloc(size_t nmemb, size_t size);