diff options
author | cflip <cflip@cflip.net> | 2023-01-11 11:34:19 -0700 |
---|---|---|
committer | cflip <cflip@cflip.net> | 2023-01-11 11:34:19 -0700 |
commit | 54d0e32bced43dc3d85b41e30bcb1fa430ae90dc (patch) | |
tree | e7d961b9dcac64e4ff06f7caa410fbeb3241672c /error.c | |
parent | 0324dda2cc779bcd6d3eb425216e29b37a9a95ed (diff) |
Use the new error function with the new window and font code
Diffstat (limited to 'error.c')
-rw-r--r-- | error.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -1,11 +1,15 @@ #include "error.h" +#include <stdarg.h> #include <stdio.h> #include <stdlib.h> -void fatal_error(const char *msg) +void fatal_error(const char *msgfmt, ...) { - perror(msg); + va_list args; + va_start(args, msgfmt); + vfprintf(stderr, msgfmt, args); + va_end(args); exit(-1); } |