Fix a segfault if rc.conf does not exist, Gentoo #214887

This commit is contained in:
Roy Marples
2008-03-26 15:10:26 +00:00
parent f90f2914b9
commit cee3ccc4c1
2 changed files with 16 additions and 9 deletions

View File

@@ -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 &&