diff options
author | Roger Dingledine <arma@torproject.org> | 2006-03-18 22:54:08 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2006-03-18 22:54:08 +0000 |
commit | 7e2aa67fcb297aa69185d1b2b2fcf46e1195f5f4 (patch) | |
tree | ad910d8beed4d64f842b7b57dad30ebe32904f2d /src/or/connection_edge.c | |
parent | 868d456c3b1674385490a378018682b2135d835d (diff) | |
download | tor-7e2aa67fcb297aa69185d1b2b2fcf46e1195f5f4.tar.gz tor-7e2aa67fcb297aa69185d1b2b2fcf46e1195f5f4.zip |
simplify when we're picking a default address for
when people ask for "serifos.exit".
svn:r6187
Diffstat (limited to 'src/or/connection_edge.c')
-rw-r--r-- | src/or/connection_edge.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/or/connection_edge.c b/src/or/connection_edge.c index c1ecb66969..ab8c7e5c3c 100644 --- a/src/or/connection_edge.c +++ b/src/or/connection_edge.c @@ -995,15 +995,12 @@ connection_ap_handshake_rewrite_and_attach(connection_t *conn, return -1; } } else { - struct in_addr in; routerinfo_t *r; conn->chosen_exit_name = tor_strdup(socks->address); r = router_get_by_nickname(conn->chosen_exit_name, 1); *socks->address = 0; if (r) { - /* XXXX Should this use server->address instead? */ - in.s_addr = htonl(r->addr); - strlcpy(socks->address, inet_ntoa(in), sizeof(socks->address)); + strlcpy(socks->address, r->address, sizeof(socks->address)); } else { log_warn(LD_APP, "Unrecognized server in exit address '%s.exit'. Refusing.", |