second argument is NULL. There are some special values:
all print all main configuration options
- configure_file print the name of the configuration file
+ config_file print the name of the configuration file
+ (configure_file will still work, for backward
+ compatibility)
routers print the routers' configurations
transports print the transports' configuration
authenticators print the authenticators' configuration
return;
}
- if (Ustrcmp(name, "configure_file") == 0)
+ if ( Ustrcmp(name, "configure_file") == 0
+ ||Ustrcmp(name, "config_file") == 0)
{
printf("%s\n", CS config_main_filename);
return;
/* Append a pre-parsed logical line to the config lines store,
this operates on a global (static) list that holds all the pre-parsed
-config lines */
+config lines, we do no further processing here, output formatting and
+honouring of <hide> or macros will be done during output */
static void
save_config_line(const uschar* line)
{
continue;
}
- /* as admin we don't care, as we do for "public" lines */
- if (admin || (!isupper(*current) && (strcmp(current, "hide") != 0)))
+ /* hidden lines (MACROS or prefixed with hide) */
+ if (!admin && (isupper(*current)
+ || (strncmp(current, "hide", 4) == 0 && isspace(current[4]))))
{
- printf("%*s%s\n", indent, "", current);
+ if (p = strchr(current, '='))
+ {
+ *p = '\0';
+ printf("%*s%s = %s\n", indent, "", current, hidden);
+ }
+ /* e.g.: hide split_spool_directory */
+ else printf("%*s\n", indent, hidden);
continue;
}
- /* hidden lines */
- if (p = strchr(current, '='))
- {
- *p = '\0';
- printf("%*s%s = %s\n", indent, "", current, hidden);
- continue;
- }
+ /* rest is public */
+ printf("%*s%s\n", indent, "", current);
+ continue;
}
}