suckless/dmenu

util.h in master
Repositories | Summary | Log | Files | README | LICENSE

util.h (366B) download


1/* See LICENSE file for copyright and license details. */
2
3#define MAX(A, B)               ((A) > (B) ? (A) : (B))
4#define MIN(A, B)               ((A) < (B) ? (A) : (B))
5#define BETWEEN(X, A, B)        ((A) <= (X) && (X) <= (B))
6#define LENGTH(X)               (sizeof (X) / sizeof (X)[0])
7
8void die(const char *fmt, ...);
9void *ecalloc(size_t nmemb, size_t size);