[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] don"t try to circuit_log_path if you"re at the exit edge of...



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

Modified Files:
	connection_edge.c 
Log Message:
don't try to circuit_log_path if you're at the exit edge of a circ


Index: connection_edge.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection_edge.c,v
retrieving revision 1.152
retrieving revision 1.153
diff -u -d -r1.152 -r1.153
--- connection_edge.c	8 Apr 2004 02:24:06 -0000	1.152
+++ connection_edge.c	8 Apr 2004 03:30:47 -0000	1.153
@@ -237,9 +237,10 @@
 
   if(conn && conn->state != AP_CONN_STATE_OPEN && conn->state != EXIT_CONN_STATE_OPEN) {
     if(rh.command == RELAY_COMMAND_END) {
-      circuit_log_path(LOG_INFO,circ);
       log_fn(LOG_INFO,"Edge got end (%s) before we're connected. Marking for close.",
         connection_edge_end_reason(cell->payload+RELAY_HEADER_SIZE, rh.length));
+      if(CIRCUIT_IS_ORIGIN(circ))
+        circuit_log_path(LOG_INFO,circ);
       conn->has_sent_end = 1; /* we just got an 'end', don't need to send one */
       connection_mark_for_close(conn, 0);
       /* XXX This is where we should check if reason is EXITPOLICY, and reattach */