summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2009-10-10 13:39:41 -0400
committerRoger Dingledine <arma@torproject.org>2009-10-10 13:39:41 -0400
commit746a19e84d1abf2804f5b4fd8bc3353b162f854c (patch)
tree53cfb6480d2fad7a5fe96a803735378000906c8b
parent047fdd4104800a46db32b043cecf0bc31d59cb70 (diff)
downloadtor-746a19e84d1abf2804f5b4fd8bc3353b162f854c.tar.gz
tor-746a19e84d1abf2804f5b4fd8bc3353b162f854c.zip
remove some dead code. some of it was tickling coverity.
-rw-r--r--ChangeLog2
-rw-r--r--src/or/connection_edge.c19
2 files changed, 0 insertions, 21 deletions
diff --git a/ChangeLog b/ChangeLog
index 35441ae78c..8fd700fc6c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -25,8 +25,6 @@ Changes in version 0.2.2.4-alpha - 2009-10-??
on 0.2.2.1-alpha.
- Fix two memory leaks in the error case of
circuit_build_times_parse_state. Bugfix on 0.2.2.2-alpha.
- - Make it explicit that we can't overflow in
- connection_ap_handshake_send_resolve. Bugfix on 0.0.7.1.
- Don't count one-hop circuits when we're estimating how long it
takes circuits to build on average. Otherwise we'll set our circuit
build timeout lower than we should. Bugfix on 0.2.2.2-alpha.
diff --git a/src/or/connection_edge.c b/src/or/connection_edge.c
index 0e6297a50a..97d6595e97 100644
--- a/src/or/connection_edge.c
+++ b/src/or/connection_edge.c
@@ -1547,18 +1547,6 @@ connection_ap_handshake_rewrite_and_attach(edge_connection_t *conn,
uint32_t answer;
struct in_addr in;
/* Reply to resolves immediately if we can. */
- if (strlen(socks->address) > RELAY_PAYLOAD_SIZE) {
- log_warn(LD_APP,"Address to be resolved is too large. Failing.");
- control_event_client_status(LOG_WARN, "SOCKS_BAD_HOSTNAME HOSTNAME=%s",
- escaped(socks->address));
- connection_ap_handshake_socks_resolved(conn,
- RESOLVED_TYPE_ERROR_TRANSIENT,
- 0,NULL,-1,TIME_MAX);
- connection_mark_unattached_ap(conn,
- END_STREAM_REASON_SOCKSPROTOCOL |
- END_STREAM_REASON_FLAG_ALREADY_SOCKS_REPLIED);
- return -1;
- }
if (tor_inet_aton(socks->address, &in)) { /* see if it's an IP already */
/* leave it in network order */
answer = in.s_addr;
@@ -2156,13 +2144,6 @@ connection_ap_handshake_send_resolve(edge_connection_t *ap_conn)
tor_assert(payload_len <= (int)sizeof(inaddr_buf));
}
- if (payload_len > MAX_SOCKS_ADDR_LEN) {
- /* This should be impossible: we don't accept addresses this big. */
- /* XXX Should we log a bug here? */
- connection_mark_unattached_ap(ap_conn, END_STREAM_REASON_INTERNAL);
- return -1;
- }
-
log_debug(LD_APP,
"Sending relay cell to begin stream %d.", ap_conn->stream_id);