From b0eaf0bc279aa0b5097160e1f6ce15e842e47095 Mon Sep 17 00:00:00 2001 From: Erik van der Kouwe Date: Mon, 4 Oct 2010 17:53:18 +0000 Subject: [PATCH] make system server vprintf check for NULL --- lib/libsys/vprintf.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/libsys/vprintf.c b/lib/libsys/vprintf.c index 4a97efe42..2749e400d 100644 --- a/lib/libsys/vprintf.c +++ b/lib/libsys/vprintf.c @@ -142,6 +142,7 @@ int vprintf(const char *fmt, va_list argp) /* A string. The other cases will join in here. */ case 's': p= va_arg(argp, char *); + if (!p) p = "(null)"; string_length: for (len= 0; p[len] != 0 && len < max; len++) {}