diff options
| author | Riley Beckett <rbeckettvt@gmail.com> | 2026-07-22 22:30:54 -0400 |
|---|---|---|
| committer | Riley Beckett <rbeckettvt@gmail.com> | 2026-07-22 22:30:54 -0400 |
| commit | a682c2cdc499bdecab81e41200f4a28b08600bfb (patch) | |
| tree | 8189e862dc63a150daa7afffebe1a2eebe91435c /snag/src/util.c | |
| parent | f253f5e3d606702688deecea2162f1c5289d277c (diff) | |
make configure posix shell instead of bash
Diffstat (limited to 'snag/src/util.c')
| -rw-r--r-- | snag/src/util.c | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/snag/src/util.c b/snag/src/util.c index 79c4b17..df1a8fd 100644 --- a/snag/src/util.c +++ b/snag/src/util.c @@ -6,18 +6,6 @@ #include "util.h" #if !DEBUG -void log(const char* format, ...) { -#else -void _log(int line, const char* file, const char* format, ...) { - fprintf(stderr, "%s:%d: info: ", file, line); -#endif - va_list args; - va_start(args, format); - vfprintf(stderr, format, args); - va_end(args); -} - -#if !DEBUG void die(const char* format, ...) { #else void _die(int line, const char* file, const char* format, ...) { @@ -34,7 +22,7 @@ void _die(int line, const char* file, const char* format, ...) { #if !DEBUG void* emalloc(size_t size, char* alloc_reason) { void* d = malloc(size); - if (d == NULL) _die("failed to allocate '%s': %s", alloc_reason, strerror(errno)); + if (d == NULL) die("failed to allocate '%s': %s", alloc_reason, strerror(errno)); return d; } #else |
