From 5a96d39542d356fc3d102d52390a55d8cb6758d3 Mon Sep 17 00:00:00 2001 From: gramanas Date: Tue, 13 Nov 2018 15:12:31 +0200 Subject: Leave no string uninitialized. --- src/ckerrlog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ckerrlog.c') diff --git a/src/ckerrlog.c b/src/ckerrlog.c index cfafb39..fe4c688 100644 --- a/src/ckerrlog.c +++ b/src/ckerrlog.c @@ -16,7 +16,7 @@ ERRLOG(logger); static int loglvl; -static char buf[STR_M]; +static char buf[STR_M] = ""; #define X(stream) static cklist *stream; CK_STREAMS @@ -44,7 +44,7 @@ void log_command(int argc,const char* argv[]) { void add_ ## stream ## _with_delim(const char *delim, \ const char *txt, \ va_list args) { \ - char tmp[STR_L]; \ + char tmp[STR_L] = ""; \ vsprintf(tmp, txt, args); \ if (stream) { \ list_add(stream, tmp); \ -- cgit v1.2.3