chiark
/
gitweb
/
~ian
/
secnet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
log: Provide system_log from the very start
[secnet.git]
/
log.c
diff --git
a/log.c
b/log.c
index 6aced817eb0aa79cc868de3a1c60fdb16a6aa782..84f5a86abd610240bff0031a805213dc2aaa4589 100644
(file)
--- a/
log.c
+++ b/
log.c
@@
-663,6
+663,16
@@
void log_from_fd(int fd, cstring_t prefix, struct log_if *log)
prefix);
}
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);
void log_module(dict_t *dict)
{
setlinebuf(stderr);