It is just too inconvenient not to have this while reading the config.
Set up a default system_log which logs to stderr. When setup_log
is called, system_log will be overwritten and this struct is no
longer used.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
prefix);
}
+static struct logfile startup_log;
+void log_early_init(void)
+{
+ logfile_file_init(&startup_log,stderr,"startup");
+ system_log=&startup_log.ops;;
+}
+
+/* for the benefit of main, really */
+void logfile_init_file(struct logfile *st, FILE *f);
+
void log_module(dict_t *dict)
{
setlinebuf(stderr);
{
dict_t *config;
+ log_early_init();
phase_hooks_init();
enter_phase(PHASE_GETOPTS);
cfl->facility=facility;
}
+void log_early_init(void);
+
/* SITE interface */
/* Pretty much a placeholder; allows starting and stopping of processing,