diff options
author | gramanas <anastasis.gramm2@gmail.com> | 2018-11-13 15:12:31 +0200 |
---|---|---|
committer | gramanas <anastasis.gramm2@gmail.com> | 2018-11-13 15:12:31 +0200 |
commit | 5a96d39542d356fc3d102d52390a55d8cb6758d3 (patch) | |
tree | 0f9e6844e880759e5b5b20b6af683a0822de410c /src/ckerrlog.c | |
parent | 2415d22c7a82396daf21dabe6191531cfa21e6a3 (diff) | |
download | ck-5a96d39542d356fc3d102d52390a55d8cb6758d3.tar.gz ck-5a96d39542d356fc3d102d52390a55d8cb6758d3.tar.bz2 ck-5a96d39542d356fc3d102d52390a55d8cb6758d3.zip |
Leave no string uninitialized.
Diffstat (limited to 'src/ckerrlog.c')
-rw-r--r-- | src/ckerrlog.c | 4 |
1 files changed, 2 insertions, 2 deletions
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); \ |