Only use the environment variable when it is not empty

This commit is contained in:
sin 2015-11-26 15:10:12 +00:00
parent b77477d377
commit 16109053f5

View file

@ -203,7 +203,7 @@ xgetenv(char *name, char *fallback)
if (name == NULL)
return fallback;
value = getenv(name);
return value ? value : fallback;
return value && value[0] ? value : fallback;
}
char *