summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrl1987 <rl1987@sdf.lonestar.org>2014-11-23 21:34:41 +0200
committerNick Mathewson <nickm@torproject.org>2014-12-21 14:48:38 -0500
commitfc7d5e598bb2494bd121e73038cf29854a23d9d5 (patch)
tree20b39d7b8c9e6058c9ba9401899129743899d5da /src
parent551221bad6a852750a9f0bd0e4e521192dbc7999 (diff)
downloadtor-fc7d5e598bb2494bd121e73038cf29854a23d9d5.tar.gz
tor-fc7d5e598bb2494bd121e73038cf29854a23d9d5.zip
Using CHANNEL_FINISHED macro in connection.c
Diffstat (limited to 'src')
-rw-r--r--src/or/connection.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/or/connection.c b/src/or/connection.c
index c9c371c001..16b359d5ed 100644
--- a/src/or/connection.c
+++ b/src/or/connection.c
@@ -544,8 +544,7 @@ connection_free_(connection_t *conn)
or_conn, TLS_CHAN_TO_BASE(or_conn->chan),
U64_PRINTF_ARG(
TLS_CHAN_TO_BASE(or_conn->chan)->global_identifier));
- if (!(TLS_CHAN_TO_BASE(or_conn->chan)->state == CHANNEL_STATE_CLOSED ||
- TLS_CHAN_TO_BASE(or_conn->chan)->state == CHANNEL_STATE_ERROR)) {
+ if (!CHANNEL_FINISHED(TLS_CHAN_TO_BASE(or_conn->chan))) {
channel_close_for_error(TLS_CHAN_TO_BASE(or_conn->chan));
}