summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-08-09 06:14:53 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-08-09 06:14:53 +0200
commite0f99a4199ade6ca2d2325d1d38a45e4ce403fa1 (patch)
tree9960d6b0042f77f2369722f09b42cd079c7053c9
parentc800a400b04b9ba25773f26e402a734a2ef3fe83 (diff)
downloadfastd-e0f99a4199ade6ca2d2325d1d38a45e4ce403fa1.tar
fastd-e0f99a4199ade6ca2d2325d1d38a45e4ce403fa1.zip
log: fix port of IPv6 addresses with hidden IP addresses
-rw-r--r--src/log.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/log.c b/src/log.c
index 8809387..8513c79 100644
--- a/src/log.c
+++ b/src/log.c
@@ -72,7 +72,7 @@ static size_t snprint_peer_address(char *buffer, size_t size, const fastd_peer_a
case AF_INET6:
if (!bind_address && conf.hide_ip_addresses)
- return snprintf_safe(buffer, size, "[hidden]:%u", ntohs(address->in.sin_port));
+ return snprintf_safe(buffer, size, "[hidden]:%u", ntohs(address->in6.sin6_port));
if (inet_ntop(AF_INET6, &address->in6.sin6_addr, addr_buf, sizeof(addr_buf))) {
char ifname_buf[IF_NAMESIZE];
if (!iface && IN6_IS_ADDR_LINKLOCAL(&address->in6.sin6_addr))