conf: replace empty strings with NULL

Avoid mixing empty strings with NULLs in configuration strings to make
the handling of default or disabled values consistent.
This commit is contained in:
Miroslav Lichvar
2020-05-20 16:20:43 +02:00
parent e555548dda
commit 60049f1551
5 changed files with 21 additions and 25 deletions

View File

@@ -267,7 +267,7 @@ LOG_FileWrite(LOG_FileID id, const char *format, ...)
if (!logfiles[id].file) {
char *logdir = CNF_GetLogDir();
if (logdir[0] == '\0') {
if (!logdir) {
LOG(LOGS_WARN, "logdir not specified");
logfiles[id].name = NULL;
return;