diff options
author | Nicholas Noll <nbnoll@eml.cc> | 2020-05-30 15:09:33 -0700 |
---|---|---|
committer | Nicholas Noll <nbnoll@eml.cc> | 2020-05-30 15:09:33 -0700 |
commit | cf65141f154651115028d6456a1d7582d30b2083 (patch) | |
tree | 731b1b1fe7e513e8e9410ad090687fa203838f43 /sys/libn/error.c | |
parent | 038ea2d0a34fb362f577e6c9884c710ebaf4042e (diff) |
many bug fixes
Diffstat (limited to 'sys/libn/error.c')
-rw-r--r-- | sys/libn/error.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/libn/error.c b/sys/libn/error.c index 9b6a28a..5595457 100644 --- a/sys/libn/error.c +++ b/sys/libn/error.c @@ -20,8 +20,8 @@ panicf(byte* fmt, ...) int n; va_list args; static byte buf[4*1024]; - va_start(args, fmt); + va_start(args, fmt); buf[0] = 'p'; buf[1] = 'a'; buf[2] = 'n'; @@ -32,7 +32,7 @@ panicf(byte* fmt, ...) n = vsnprintf(buf+7, arrlen(buf)-8, fmt, args); if (n < 0) return; - buf[n] = 0; + buf[n+7] = 0; perror(buf); va_end(args); |