[or-cvs] kill -USR2 now moves all logs to loglevel debug

Roger Dingledine arma at seul.org
Sat Nov 20 07:33:55 UTC 2004


Update of /home2/or/cvsroot/tor/src/common
In directory moria.mit.edu:/home2/arma/work/onion/cvs/tor/src/common

Modified Files:
	log.c log.h 
Log Message:
kill -USR2 now moves all logs to loglevel debug
plus fix some typos


Index: log.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/common/log.c,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -d -r1.71 -r1.72
--- log.c	20 Nov 2004 07:08:00 -0000	1.71
+++ log.c	20 Nov 2004 07:33:53 -0000	1.72
@@ -441,6 +441,15 @@
   return min;
 }
 
+/** Switch all logs to output at most verbose level. */
+void switch_logs_debug(void)
+{
+  logfile_t *lf;
+  for (lf = logfiles; lf; lf=lf->next) {
+    lf->loglevel = LOG_DEBUG;
+  }
+}
+
 /*
   Local Variables:
   mode:c

Index: log.h
===================================================================
RCS file: /home2/or/cvsroot/tor/src/common/log.h,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -d -r1.35 -r1.36
--- log.h	15 Nov 2004 23:30:26 -0000	1.35
+++ log.h	20 Nov 2004 07:33:53 -0000	1.36
@@ -64,6 +64,7 @@
 #endif
 int add_callback_log(int loglevelMin, int loglevelMax, log_callback cb);
 int get_min_log_level(void);
+void switch_logs_debug(void);
 void close_logs(void);
 void reset_logs(void);
 void add_temp_log(void);



More information about the tor-commits mailing list