From 4bfe894d2f35c7f03da453ca585a594061bc227c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Tue, 26 Feb 2019 18:56:08 +0100 Subject: Fix problem with uninitialized memmory. --- calendar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'calendar.c') diff --git a/calendar.c b/calendar.c index 6f1756a3..a60d8ea2 100644 --- a/calendar.c +++ b/calendar.c @@ -51,7 +51,7 @@ int handle_dir(vcomponent* cal, char* path) { DIR* dir = opendir(path); /* Buffer for holding search path and filename */ - char buf[PATH_MAX]; + char buf[PATH_MAX] = { [0 ... PATH_MAX - 1] = '\0' }; strcpy(buf, path); int path_len = strlen(path) + 1; -- cgit v1.2.3