settings: Reduce log verbosity if files can't be opened

Basically reintroducing 2a38b4556e.
This commit is contained in:
Tobias Brunner
2014-05-15 11:28:09 +02:00
parent 8b43c9ba34
commit f65ac98c64
2 changed files with 11 additions and 2 deletions
+10 -1
View File
@@ -255,7 +255,16 @@ bool settings_parser_parse_file(section_t *root, char *name)
helper->file_include(helper, name);
if (!settings_parser_open_next_file(helper))
{
DBG1(DBG_CFG, "failed to open config file '%s'", name);
#ifdef STRONGSWAN_CONF
if (streq(name, STRONGSWAN_CONF))
{
DBG2(DBG_CFG, "failed to open config file '%s'", name);
}
else
#endif
{
DBG1(DBG_CFG, "failed to open config file '%s'", name);
}
}
else
{
+1 -1
View File
@@ -111,7 +111,7 @@ METHOD(parser_helper_t, file_next, parser_helper_file_t*,
array_insert(this->files, ARRAY_TAIL, next);
return &next->public;
}
PARSER_DBG1(&this->public, "unable to open '%s'", name);
PARSER_DBG2(&this->public, "unable to open '%s'", name);
parser_helper_file_destroy(next);
}
file->matches->destroy(file->matches);