aboutsummaryrefslogtreecommitdiff
path: root/src/or/directory.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2016-04-01 08:15:05 -0400
committerNick Mathewson <nickm@torproject.org>2016-04-01 08:15:05 -0400
commit9e57ffa520bb0e8b9a7dd32e005e6b29a3f8bdfa (patch)
treed6a941ed74531bb2ad17e580f5b47fa1c32abf0f /src/or/directory.c
parent93c311daa8e7fd7021efbf3e58c1b66a3e791666 (diff)
parente247093e0efba100ec6f3abdfa9d3433d51389f0 (diff)
downloadtor-9e57ffa520bb0e8b9a7dd32e005e6b29a3f8bdfa.tar.gz
tor-9e57ffa520bb0e8b9a7dd32e005e6b29a3f8bdfa.zip
Merge branch 'maint-0.2.8'
Diffstat (limited to 'src/or/directory.c')
-rw-r--r--src/or/directory.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/or/directory.c b/src/or/directory.c
index 1241036912..11f7d06b75 100644
--- a/src/or/directory.c
+++ b/src/or/directory.c
@@ -2960,10 +2960,8 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers,
}
if (1) {
- struct in_addr in;
tor_addr_t addr;
- if (tor_inet_aton((TO_CONN(conn))->address, &in)) {
- tor_addr_from_ipv4h(&addr, ntohl(in.s_addr));
+ if (tor_addr_parse(&addr, (TO_CONN(conn))->address) >= 0) {
geoip_note_client_seen(GEOIP_CLIENT_NETWORKSTATUS,
&addr, NULL,
time(NULL));