summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Ransom <rransom.8774@gmail.com>2011-12-06 05:02:58 -0800
committerNick Mathewson <nickm@torproject.org>2011-12-09 11:28:42 -0500
commit832bfc3c462f0b8dc1668b5b580f656a2b457a96 (patch)
tree2e42d6754dea46baf71ded675429ad669c6712cf
parent7b6b2d5fb8c760a506a052aa0fba7ba6a8fe4e77 (diff)
downloadtor-832bfc3c462f0b8dc1668b5b580f656a2b457a96.tar.gz
tor-832bfc3c462f0b8dc1668b5b580f656a2b457a96.zip
Clear stream-isolation state on rend circs if needed to attach streams
Fixes bug 4655; bugfix on 0.2.3.3-alpha.
-rw-r--r--changes/bug465510
-rw-r--r--src/or/rendclient.c4
2 files changed, 13 insertions, 1 deletions
diff --git a/changes/bug4655 b/changes/bug4655
new file mode 100644
index 0000000000..b91d87123c
--- /dev/null
+++ b/changes/bug4655
@@ -0,0 +1,10 @@
+ o Minor bugfixes:
+
+ - If we can't attach streams to a rendezvous circuit when we
+ finish connecting to a hidden service, clear the rendezvous
+ circuit's stream-isolation state and try to attach streams
+ again. Previously, we cleared rendezvous circuits' isolation
+ state either too early (if they were freshly built) or not at
+ all (if they had been built earlier and were cannibalized).
+ Bugfix on 0.2.3.3-alpha; fixes bug 4655.
+
diff --git a/src/or/rendclient.c b/src/or/rendclient.c
index 5429b6c7e3..c4744731df 100644
--- a/src/or/rendclient.c
+++ b/src/or/rendclient.c
@@ -892,10 +892,12 @@ rend_client_receive_rendezvous(origin_circuit_t *circ, const uint8_t *request,
onion_append_to_cpath(&circ->cpath, hop);
circ->build_state->pending_final_cpath = NULL; /* prevent double-free */
+
/* XXXX023 This is a pretty brute-force approach. It'd be better to
* attach only the connections that are waiting on this circuit, rather
* than trying to attach them all. See comments bug 743. */
- connection_ap_attach_pending();
+ circuit_try_attaching_streams(circ);
+
memset(keys, 0, sizeof(keys));
return 0;
err: