May I suggest to not get this patch? This is not the correct way to fix the problem reported by cppcheck.
----- David Maciejak <[email protected]> a écrit : > set default path init value to remove some cppcheck warning > > --- > src/defaults.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/defaults.c b/src/defaults.c > index 7d66372..c6748d5 100644 > --- a/src/defaults.c > +++ b/src/defaults.c > @@ -798,7 +798,7 @@ static void initDefaults(void) > static WMPropList *readGlobalDomain(const char *domainName, Bool > requireDictionary) > { > WMPropList *globalDict = NULL; > - char path[PATH_MAX]; > + char path[PATH_MAX] = ""; > struct stat stbuf; > > snprintf(path, sizeof(path), "%s/%s/%s", SYSCONFDIR, > GLOBAL_DEFAULTS_SUBDIR, domainName); > -- > 1.8.3.2 -- To unsubscribe, send mail to [email protected].
