aboutsummaryrefslogtreecommitdiff
path: root/src/or/channel.c
diff options
context:
space:
mode:
authorAndrea Shepard <andrea@torproject.org>2013-09-23 09:37:26 -0700
committerNick Mathewson <nickm@torproject.org>2013-09-24 10:42:12 -0400
commit938ee9b24dfda03a68a71d43b88e9fb00a90f9c8 (patch)
tree4a866ec40c960ec5f40a9aee709d66fd409f75ed /src/or/channel.c
parent116e6af7a7024b4731ce6af75e8c5c5167314048 (diff)
downloadtor-938ee9b24dfda03a68a71d43b88e9fb00a90f9c8.tar.gz
tor-938ee9b24dfda03a68a71d43b88e9fb00a90f9c8.zip
Always call circuit_n_chan_done(chan, 0) from channel_closed()
Diffstat (limited to 'src/or/channel.c')
-rw-r--r--src/or/channel.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/or/channel.c b/src/or/channel.c
index 602797d0dc..1fb39b88ca 100644
--- a/src/or/channel.c
+++ b/src/or/channel.c
@@ -1292,11 +1292,10 @@ channel_closed(channel_t *chan)
if (chan->state == CHANNEL_STATE_CLOSED ||
chan->state == CHANNEL_STATE_ERROR) return;
- if (chan->reason_for_closing == CHANNEL_CLOSE_FOR_ERROR) {
- /* Inform any pending (not attached) circs that they should
- * give up. */
- circuit_n_chan_done(chan, 0);
- }
+ /* Inform any pending (not attached) circs that they should
+ * give up. */
+ circuit_n_chan_done(chan, 0);
+
/* Now close all the attached circuits on it. */
circuit_unlink_all_from_channel(chan, END_CIRC_REASON_CHANNEL_CLOSED);