bugfix: when you finish answering a 'resolve' request, hold the

connection open so you can flush the answer


svn:r2148
This commit is contained in:
Roger Dingledine 2004-08-05 00:39:23 +00:00
parent 54dd90d391
commit de0f72ce2a
2 changed files with 3 additions and 0 deletions

View File

@ -379,6 +379,7 @@ static int connection_ap_handshake_process_socks(connection_t *conn) {
conn->socks_request->has_finished = 1; conn->socks_request->has_finished = 1;
conn->has_sent_end = 1; conn->has_sent_end = 1;
connection_mark_for_close(conn); connection_mark_for_close(conn);
conn->hold_open_until_flushed = 1;
return 0; return 0;
} }
answer = htonl(client_dns_lookup_entry(socks->address)); answer = htonl(client_dns_lookup_entry(socks->address));
@ -388,6 +389,7 @@ static int connection_ap_handshake_process_socks(connection_t *conn) {
conn->socks_request->has_finished = 1; conn->socks_request->has_finished = 1;
conn->has_sent_end = 1; conn->has_sent_end = 1;
connection_mark_for_close(conn); connection_mark_for_close(conn);
conn->hold_open_until_flushed = 1;
return 0; return 0;
} }
} }

View File

@ -581,6 +581,7 @@ connection_edge_process_relay_cell_not_open(
conn->socks_request->has_finished = 1; conn->socks_request->has_finished = 1;
conn->has_sent_end = 1; conn->has_sent_end = 1;
connection_mark_for_close(conn); connection_mark_for_close(conn);
conn->hold_open_until_flushed = 1;
return 0; return 0;
} }