Fix a segfault if rc.conf does not exist, Gentoo #214887
This commit is contained in:
@@ -203,6 +203,9 @@ char *rc_config_value(RC_STRINGLIST *list, const char *entry)
|
||||
RC_STRING *line;
|
||||
char *p;
|
||||
|
||||
if (!list)
|
||||
return NULL;
|
||||
|
||||
TAILQ_FOREACH(line, list, entries) {
|
||||
p = strchr(line->value, '=');
|
||||
if (p &&
|
||||
|
||||
Reference in New Issue
Block a user