[or-cvs] finally tracked down the seg fault

Roger Dingledine arma at seul.org
Sun Sep 14 06:43:21 UTC 2003


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

Modified Files:
	connection.c main.c 
Log Message:
finally tracked down the seg fault


Index: connection.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection.c,v
retrieving revision 1.89
retrieving revision 1.90
diff -u -d -r1.89 -r1.90
--- connection.c	14 Sep 2003 02:58:50 -0000	1.89
+++ connection.c	14 Sep 2003 06:43:18 -0000	1.90
@@ -249,7 +249,7 @@
   }
 
   if(connection_init_accepted_conn(newconn) < 0) {
-    connection_free(newconn);
+    newconn->marked_for_close = 1;
     return 0;
   }
   return 0;

Index: main.c
===================================================================
RCS file: /home/or/cvsroot/src/or/main.c,v
retrieving revision 1.91
retrieving revision 1.92
diff -u -d -r1.91 -r1.92
--- main.c	13 Sep 2003 21:53:38 -0000	1.91
+++ main.c	14 Sep 2003 06:43:18 -0000	1.92
@@ -676,6 +676,7 @@
       continue; /* we only want to list ones that successfully handshaked */
     router = router_get_by_addr_port(conn->addr,conn->port);
     if(!router) {
+      /* XXX this legitimately happens when conn is an OP. How to detect this? */
       log(LOG_ERR,"build_directory(): couldn't find router %d:%d!",
           conn->addr,conn->port);
       continue;



More information about the tor-commits mailing list