[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] don"t call circuit_n_conn_done() if the closing conn is alr...
Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or
Modified Files:
circuituse.c
Log Message:
don't call circuit_n_conn_done() if the closing conn is already open.
Index: circuituse.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/circuituse.c,v
retrieving revision 1.118
retrieving revision 1.119
diff -u -p -d -r1.118 -r1.119
--- circuituse.c 21 Mar 2006 21:22:52 -0000 1.118
+++ circuituse.c 21 Mar 2006 22:22:48 -0000 1.119
@@ -524,8 +524,11 @@ circuit_about_to_close_connection(connec
*/
switch (conn->type) {
case CONN_TYPE_OR: {
- /* Inform any pending (not attached) circs that they should give up. */
- circuit_n_conn_done(conn, 0);
+ if (connection_state_is_open(conn)) {
+ /* Inform any pending (not attached) circs that they should
+ * give up. */
+ circuit_n_conn_done(conn, 0);
+ }
/* Now close all the attached circuits on it. */
circuit_unlink_all_from_or_conn(conn, END_CIRC_REASON_OR_CONN_CLOSED);
return;