diff options
-rw-r--r-- | sbin/dump/optr.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/dump/optr.c b/sbin/dump/optr.c index bc00b1a..97b7438 100644 --- a/sbin/dump/optr.c +++ b/sbin/dump/optr.c @@ -233,10 +233,10 @@ msg(const char *fmt, ...) (void) fprintf(stderr, "pid=%d ", getpid()); #endif va_start(ap, fmt); - (void) vfprintf(stderr, fmt, ap); + (void) vsnprintf(lastmsg, sizeof(lastmsg), fmt, ap); + (void) fprintf(stderr, lastmsg); (void) fflush(stdout); (void) fflush(stderr); - (void) vsnprintf(lastmsg, sizeof(lastmsg), fmt, ap); va_end(ap); } |