[or-cvs] clean up string printing in relay logs

Roger Dingledine arma at seul.org
Thu Jan 6 19:19:15 UTC 2005


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

Modified Files:
	main.c relay.c 
Log Message:
clean up string printing in relay logs


Index: main.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/main.c,v
retrieving revision 1.413
retrieving revision 1.414
diff -u -d -r1.413 -r1.414
--- main.c	5 Jan 2005 06:40:47 -0000	1.413
+++ main.c	6 Jan 2005 19:19:12 -0000	1.414
@@ -240,6 +240,8 @@
   if (conn->marked_for_close)
     return;
 
+  /* post 0.0.9, 
+
   /* see http://www.greenend.org.uk/rjk/2001/06/poll.html for
    * discussion of POLLIN vs POLLHUP */
   if (!(poll_array[i].revents & (POLLIN|POLLHUP|POLLERR)))

Index: relay.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/relay.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- relay.c	6 Jan 2005 19:17:01 -0000	1.34
+++ relay.c	6 Jan 2005 19:19:13 -0000	1.35
@@ -507,10 +507,10 @@
       }
       addr = ntohl(get_uint32(cell->payload+RELAY_HEADER_SIZE+1));
       if (addr) {
-        log_fn(LOG_INFO,"Address %s refused due to exit policy. Retrying.",
+        log_fn(LOG_INFO,"Address '%s' refused due to exit policy. Retrying.",
                conn->socks_request->address);
       } else {
-        log_fn(LOG_INFO,"Address %s resolved to 0.0.0.0. Closing,",
+        log_fn(LOG_INFO,"Address '%s' resolved to 0.0.0.0. Closing,",
                conn->socks_request->address);
         conn->has_sent_end = 1; /* we just got an 'end', don't need to send one */
         connection_mark_for_close(conn);
@@ -525,7 +525,7 @@
         return 0; /* this circuit is screwed and doesn't know it yet */
       }
       if (connection_ap_can_use_exit(conn, exitrouter)) {
-        log_fn(LOG_NOTICE,"Exitrouter %s seems to be more restrictive than its exit policy. Not using this router as exit for now.", exitrouter->nickname);
+        log_fn(LOG_NOTICE,"Exitrouter '%s' seems to be more restrictive than its exit policy. Not using this router as exit for now.", exitrouter->nickname);
         addr_policy_free(exitrouter->exit_policy);
         exitrouter->exit_policy =
           router_parse_addr_policy_from_string("reject *:*");



More information about the tor-commits mailing list