Commit cce16a93 authored by Jigsaw52's avatar Jigsaw52
Browse files

Improve logging of included config files

parent 42dfcd0a
......@@ -151,6 +151,8 @@ config_get_lines_aux(const char *string, config_line_t **result, int extended,
if (allow_include && !strcmp(k, "%include") && handle_include) {
tor_free(k);
include_used = 1;
log_notice(LD_CONFIG, "Processing configuration path \"%s\" at "
"recursion level %d.", v, recursion_level);
config_line_t *include_list;
if (handle_include(v, recursion_level, extended, &include_list,
......@@ -161,9 +163,6 @@ config_get_lines_aux(const char *string, config_line_t **result, int extended,
tor_free(v);
return -1;
}
log_notice(LD_CONFIG, "Included configuration file or "
"directory at recursion level %d: \"%s\".",
recursion_level, v);
*next = include_list;
if (list_last)
next = &list_last->next;
......
......@@ -152,6 +152,7 @@ config_process_include(const char *path, int recursion_level, int extended,
int rv = -1;
SMARTLIST_FOREACH_BEGIN(config_files, const char *, config_file) {
log_notice(LD_CONFIG, "Including configuration file \"%s\".", config_file);
config_line_t *included_config = NULL;
config_line_t *included_config_last = NULL;
if (config_get_included_config(config_file, recursion_level, extended,
......
Included configuration .*directory at recursion level 1.*included
Processing configuration path \".*included\" at recursion level 1\.
Included configuration file .*at recursion level 2.*nested\.inc
Processing configuration path \".*nested\.inc\" at recursion level 2\.
Included configuration .*directory at recursion level 1.*included
Processing configuration path \".*included\" at recursion level 1\.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment