summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2008-08-05 20:18:28 +0000
committerNick Mathewson <nickm@torproject.org>2008-08-05 20:18:28 +0000
commit645cbd690b3c97452846aa360729773c76ff3b52 (patch)
treeb52cc3da073a32638896228070582e1c0afdb56c /src/common
parent960a0f0a994ba23480e14ffe5179160194fd9616 (diff)
downloadtor-645cbd690b3c97452846aa360729773c76ff3b52.tar.gz
tor-645cbd690b3c97452846aa360729773c76ff3b52.zip
r17643@31-33-44: nickm | 2008-08-05 16:18:25 -0400
Oops. Remove code to set (nonportable) sin_len fields. Added it to try to fix a bug that turned out to be something else. svn:r16436
Diffstat (limited to 'src/common')
-rw-r--r--src/common/address.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/common/address.c b/src/common/address.c
index 711dc16c35..e5b11a4ffd 100644
--- a/src/common/address.c
+++ b/src/common/address.c
@@ -72,7 +72,6 @@ tor_addr_to_sockaddr(const tor_addr_t *a,
if (len < sizeof(struct sockaddr_in))
return -1;
sin = (struct sockaddr_in *)sa_out;
- sin->sin_len = sizeof(*sin);
sin->sin_family = AF_INET;
sin->sin_port = htons(port);
sin->sin_addr.s_addr = tor_addr_to_ipv4n(a);
@@ -83,7 +82,6 @@ tor_addr_to_sockaddr(const tor_addr_t *a,
return -1;
sin6 = (struct sockaddr_in6 *)sa_out;
memset(sin6, 0, sizeof(struct sockaddr_in6));
- sin6->sin6_len = sizeof(sin6);
sin6->sin6_family = AF_INET6;
sin6->sin6_port = htons(port);
memcpy(&sin6->sin6_addr, &a->addr.in6_addr, sizeof(struct in6_addr));