summaryrefslogtreecommitdiff
path: root/src/or/connection_or.c
diff options
context:
space:
mode:
authorAndrea Shepard <andrea@torproject.org>2012-11-09 14:06:54 -0800
committerAndrea Shepard <andrea@torproject.org>2012-11-10 02:35:47 -0800
commit8124398835097c3edfe0200a307092b71acfe0a0 (patch)
tree3aae724a12a4fdf001e64329ead08e887b1adf7b /src/or/connection_or.c
parent9f3f5372b880b3372fd7b9fc98bd3d78f969390a (diff)
downloadtor-8124398835097c3edfe0200a307092b71acfe0a0.tar.gz
tor-8124398835097c3edfe0200a307092b71acfe0a0.zip
Check for orconns in connection_mark_for_close and connection_mark_and_flush, and pass the call through channel_close_for_error with a warning to avoid asserts
Diffstat (limited to 'src/or/connection_or.c')
-rw-r--r--src/or/connection_or.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/or/connection_or.c b/src/or/connection_or.c
index 9cd56bb89c..1db2def848 100644
--- a/src/or/connection_or.c
+++ b/src/or/connection_or.c
@@ -1143,8 +1143,8 @@ connection_or_close_normally(or_connection_t *orconn, int flush)
channel_t *chan = NULL;
tor_assert(orconn);
- if (flush) connection_mark_and_flush(TO_CONN(orconn));
- else connection_mark_for_close(TO_CONN(orconn));
+ if (flush) connection_mark_and_flush_internal(TO_CONN(orconn));
+ else connection_mark_for_close_internal(TO_CONN(orconn));
if (orconn->chan) {
chan = TLS_CHAN_TO_BASE(orconn->chan);
/* Don't transition if we're already in closing, closed or error */
@@ -1166,8 +1166,8 @@ connection_or_close_for_error(or_connection_t *orconn, int flush)
channel_t *chan = NULL;
tor_assert(orconn);
- if (flush) connection_mark_and_flush(TO_CONN(orconn));
- else connection_mark_for_close(TO_CONN(orconn));
+ if (flush) connection_mark_and_flush_internal(TO_CONN(orconn));
+ else connection_mark_for_close_internal(TO_CONN(orconn));
if (orconn->chan) {
chan = TLS_CHAN_TO_BASE(orconn->chan);
/* Don't transition if we're already in closing, closed or error */