From f21d46ea7def76221c4173f644eb2188ae9edbb1 Mon Sep 17 00:00:00 2001 From: Anselm R Garbe Date: Sat, 8 Dec 2012 10:13:01 +0100 Subject: continued with draw.c abstraction, also started util.{h,c} implementation, that will be used by draw.c as well --- dwm.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) (limited to 'dwm.c') diff --git a/dwm.c b/dwm.c index 8b67cea..d9443da 100644 --- a/dwm.c +++ b/dwm.c @@ -41,6 +41,7 @@ #endif /* XINERAMA */ #include "draw.h" +#include "util.h" /* macros */ #define BUTTONMASK (ButtonPressMask|ButtonReleaseMask) @@ -49,8 +50,6 @@ * MAX(0, MIN((y)+(h),(m)->wy+(m)->wh) - MAX((y),(m)->wy))) #define ISVISIBLE(C) ((C->tags & C->mon->tagset[C->mon->seltags])) #define LENGTH(X) (sizeof X / sizeof X[0]) -#define MAX(A, B) ((A) > (B) ? (A) : (B)) -#define MIN(A, B) ((A) < (B) ? (A) : (B)) #define MOUSEMASK (BUTTONMASK|PointerMotionMask) #define WIDTH(X) ((X)->w + 2 * (X)->bw) #define HEIGHT(X) ((X)->h + 2 * (X)->bw) @@ -176,7 +175,6 @@ static Monitor *createmon(void); static void destroynotify(XEvent *e); static void detach(Client *c); static void detachstack(Client *c); -static void die(const char *errstr, ...); static Monitor *dirtomon(int dir); static void drawbar(Monitor *m); static void drawbars(void); @@ -695,16 +693,6 @@ detachstack(Client *c) { } } -void -die(const char *errstr, ...) { - va_list ap; - - va_start(ap, errstr); - vfprintf(stderr, errstr, ap); - va_end(ap); - exit(EXIT_FAILURE); -} - Monitor * dirtomon(int dir) { Monitor *m = NULL; -- cgit v1.2.3-13-gbd6f