diff options
author | Andrea Shepard <andrea@torproject.org> | 2012-10-01 21:03:38 -0700 |
---|---|---|
committer | Andrea Shepard <andrea@torproject.org> | 2012-10-10 00:44:47 -0700 |
commit | 49d534e524090a0270a9d43822a42e5676b3c63f (patch) | |
tree | b2831711aaaf179f8d668f627fbbb7dad060da8c /src/or/circuitmux.c | |
parent | c9607694c971a1f77531437ec61dc38c7d5d9ee3 (diff) | |
download | tor-49d534e524090a0270a9d43822a42e5676b3c63f.tar.gz tor-49d534e524090a0270a9d43822a42e5676b3c63f.zip |
New and improved circuitmux_detach_all_circuits(), now without the stupid
Diffstat (limited to 'src/or/circuitmux.c')
-rw-r--r-- | src/or/circuitmux.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/or/circuitmux.c b/src/or/circuitmux.c index d4ea643679..7be68583c1 100644 --- a/src/or/circuitmux.c +++ b/src/or/circuitmux.c @@ -369,24 +369,24 @@ circuitmux_detach_all_circuits(circuitmux_t *cmux) if (circ) { /* Clear the circuit's mux for this direction */ if (to_remove->muxinfo.direction == CELL_DIRECTION_OUT) { - /* Clear n_mux */ - circ->n_mux = NULL; /* * Update active_circuits et al.; this does policy notifies, so * comes before freeing policy data */ circuitmux_make_circuit_inactive(cmux, circ, CELL_DIRECTION_OUT); + /* Clear n_mux */ + circ->n_mux = NULL; } else if (circ->magic == OR_CIRCUIT_MAGIC) { /* - * It has a sensible p_chan and direction == CELL_DIRECTION_IN, - * so clear p_mux. - */ - TO_OR_CIRCUIT(circ)->p_mux = NULL; - /* * Update active_circuits et al.; this does policy notifies, so * comes before freeing policy data */ circuitmux_make_circuit_inactive(cmux, circ, CELL_DIRECTION_IN); + /* + * It has a sensible p_chan and direction == CELL_DIRECTION_IN, + * so clear p_mux. + */ + TO_OR_CIRCUIT(circ)->p_mux = NULL; } else { /* Complain and move on */ log_warn(LD_CIRC, |