summaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2013-06-10 12:26:39 -0400
committerNick Mathewson <nickm@torproject.org>2013-06-10 12:26:39 -0400
commit607b29ae1abe7da7d06e4e9282ed88a2dd7fe8d4 (patch)
tree6ada8daa1215ad6db0c4b51629c5389b0091fbb5 /src/or
parentc860a96ecb652d76dc23f2b490db4f5a95e9b0c3 (diff)
parent4835faebf533f93eb390649dfcb5c8cc0289e3d3 (diff)
downloadtor-607b29ae1abe7da7d06e4e9282ed88a2dd7fe8d4.tar.gz
tor-607b29ae1abe7da7d06e4e9282ed88a2dd7fe8d4.zip
Merge remote-tracking branch 'origin/maint-0.2.3' into maint-0.2.4
Diffstat (limited to 'src/or')
-rw-r--r--src/or/connection_edge.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/or/connection_edge.c b/src/or/connection_edge.c
index 4d317d0bd9..bb7ffb9a40 100644
--- a/src/or/connection_edge.c
+++ b/src/or/connection_edge.c
@@ -2652,12 +2652,13 @@ connection_exit_connect(edge_connection_t *edge_conn)
conn->state = EXIT_CONN_STATE_OPEN;
if (connection_get_outbuf_len(conn)) {
- /* in case there are any queued data cells */
- log_warn(LD_BUG,"newly connected conn had data waiting!");
-// connection_start_writing(conn);
+ /* in case there are any queued data cells, from e.g. optimistic data */
+ IF_HAS_NO_BUFFEREVENT(conn)
+ connection_watch_events(conn, READ_EVENT|WRITE_EVENT);
+ } else {
+ IF_HAS_NO_BUFFEREVENT(conn)
+ connection_watch_events(conn, READ_EVENT);
}
- IF_HAS_NO_BUFFEREVENT(conn)
- connection_watch_events(conn, READ_EVENT);
/* also, deliver a 'connected' cell back through the circuit. */
if (connection_edge_is_rendezvous_stream(edge_conn)) {