[or-cvs] when we had multiple conns on a circuit, we"d tell the wrong

Roger Dingledine arma at seul.org
Fri Feb 28 23:49:55 UTC 2003


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

Modified Files:
	connection.c 
Log Message:
when we had multiple conns on a circuit, we'd tell the wrong
one to stop reading


Index: connection.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- connection.c	18 Feb 2003 01:35:55 -0000	1.36
+++ connection.c	28 Feb 2003 23:49:52 -0000	1.37
@@ -615,7 +615,7 @@
     return -1;
   }
 
-  log(LOG_DEBUG,"connection_package_raw_inbuf(): Packaging %d bytes (%d waiting).",cell.length, amount_to_process);
+  log(LOG_DEBUG,"connection_package_raw_inbuf(): (%d) Packaging %d bytes (%d waiting).",conn->s,cell.length, amount_to_process);
 
   *(uint16_t *)(cell.payload+2) = htons(conn->topic_id);
   *cell.payload = TOPIC_COMMAND_DATA;
@@ -631,7 +631,7 @@
     }
     assert(conn->n_receive_topicwindow > 0);
     if(--conn->n_receive_topicwindow <= 0) { /* is it 0 after decrement? */
-      connection_stop_reading(circ->n_conn);
+      connection_stop_reading(conn);
       log(LOG_DEBUG,"connection_package_raw_inbuf(): receive_topicwindow at exit reached 0.");
       return 0; /* don't process the inbuf any more */
     }
@@ -646,7 +646,7 @@
     }
     assert(conn->p_receive_topicwindow > 0);
     if(--conn->p_receive_topicwindow <= 0) { /* is it 0 after decrement? */
-      connection_stop_reading(circ->p_conn);
+      connection_stop_reading(conn);
       log(LOG_DEBUG,"connection_package_raw_inbuf(): receive_topicwindow at AP reached 0.");
       return 0; /* don't process the inbuf any more */
     }



More information about the tor-commits mailing list