diff options
author | Robert Ransom <rransom.8774@gmail.com> | 2011-10-23 14:27:56 -0700 |
---|---|---|
committer | Sebastian Hahn <sebastian@torproject.org> | 2011-10-26 23:20:56 +0200 |
commit | af12c39d6de5bbcd24915db3c4cc9404f102ac02 (patch) | |
tree | d54e82419530e0248367fdba1547a7b7d0e0dec9 /src/or/connection_or.c | |
parent | 638fdedcf16cf7d6f7c586d36f7ef335c1c9714f (diff) | |
download | tor-af12c39d6de5bbcd24915db3c4cc9404f102ac02.tar.gz tor-af12c39d6de5bbcd24915db3c4cc9404f102ac02.zip |
Don't use any OR connection which sent us a CREATE_FAST cell for an EXTEND
Fix suggested by Nick Mathewson.
Diffstat (limited to 'src/or/connection_or.c')
-rw-r--r-- | src/or/connection_or.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/or/connection_or.c b/src/or/connection_or.c index 95cc02e34f..35f6da9214 100644 --- a/src/or/connection_or.c +++ b/src/or/connection_or.c @@ -519,6 +519,11 @@ connection_or_get_for_extend(const char *digest, tor_assert(tor_memeq(conn->identity_digest, digest, DIGEST_LEN)); if (conn->_base.marked_for_close) continue; + /* Never return a connection on which the other end appears to be + * a client. */ + if (conn->is_connection_with_client) { + continue; + } /* Never return a non-open connection. */ if (conn->_base.state != OR_CONN_STATE_OPEN) { /* If the address matches, don't launch a new connection for this |