Krolyxon
Commit bb4edc7

Branches

Refs →

nsxivbb4edc7

Renamed FATAL to DIE

Author
Bert
Date
2011-01-18 17:21 +0100
Parent
2a2f030
Commit
bb4edc756c7ceddb0f13194929cd1d363c85d653

+5 −5

3 files changed

  1. M image.c +1 −1
  2. M sxiv.h +1 −1
  3. M window.c +3 −3
M image.c View
@@ -40,7 +40,7 @@ void img_load(img_t *img, char *filename) {
4040 imlib_free_image();
4141
4242 if (!(img->im = imlib_load_image(filename)))
43− FATAL("could not open image: %s", filename);
43+ DIE("could not open image: %s", filename);
4444
4545 imlib_context_set_image(img->im);
4646
M sxiv.h View
@@ -30,7 +30,7 @@
3030 fprintf(stderr, "\n"); \
3131 } while (0)
3232
33−#define FATAL(...) \
33+#define DIE(...) \
3434 do { \
3535 fprintf(stderr, "sxiv: %s:%d: error: ", __FILE__, __LINE__); \
3636 fprintf(stderr, __VA_ARGS__); \
M window.c View
@@ -37,7 +37,7 @@ void win_open(win_t *win) {
3737 e = &win->env;
3838
3939 if (!(e->dpy = XOpenDisplay(NULL)))
40− FATAL("could not open display");
40+ DIE("could not open display");
4141
4242 e->scr = DefaultScreen(e->dpy);
4343 e->scrw = DisplayWidth(e->dpy, e->scr);
@@ -49,7 +49,7 @@ void win_open(win_t *win) {
4949
5050 if (!XAllocNamedColor(e->dpy, DefaultColormap(e->dpy, e->scr), BG_COLOR,
5151 &bgcol, &bgcol))
52− FATAL("could not allocate color: %s", BG_COLOR);
52+ DIE("could not allocate color: %s", BG_COLOR);
5353
5454 if (win->w > e->scrw)
5555 win->w = e->scrw;
@@ -67,7 +67,7 @@ void win_open(win_t *win) {
6767 win->x, win->y, win->w, win->h, 0,
6868 e->depth, InputOutput, e->vis, mask, &attr);
6969 if (win->xwin == None)
70− FATAL("could not create window");
70+ DIE("could not create window");
7171
7272 XSelectInput(e->dpy, win->xwin,
7373 StructureNotifyMask | ExposureMask | KeyPressMask);