mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
clean up logging, allow user to specify log files
If DebugLogFile is specified, log to it at -l debug If LogFile is specified, log to it at the -l from the commandline (default info) If no LogFile *and* not a Daemon, then log to stdout. Make conn->s = -1 by default (this might break things) When kill -USR1, prefer to log at INFO, but make sure they always see it. svn:r596
This commit is contained in:
@@ -75,11 +75,6 @@ logv(int severity, const char *funcname, const char *format, va_list ap)
|
||||
assert(format);
|
||||
if (severity < loglevel)
|
||||
return;
|
||||
if (!logfiles) {
|
||||
/* XXX This is a temporary measure until we get configuration support
|
||||
for logfiles. */
|
||||
add_stream_log(loglevel, "<stdout>", stdout);
|
||||
}
|
||||
for (lf = logfiles; lf; lf = lf->next) {
|
||||
if (severity < lf->loglevel || severity > lf->max_loglevel)
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user