From 87e328a1fbfcacafc013ba580d31dd4123f1e7e2 Mon Sep 17 00:00:00 2001 From: Peter Powell Date: Fri, 13 Jul 2018 00:47:53 +0100 Subject: Add the family() member to the sockaddrs union. --- src/modules/m_cloaking.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/modules/m_cloaking.cpp') diff --git a/src/modules/m_cloaking.cpp b/src/modules/m_cloaking.cpp index 515244231..87ff14a9d 100644 --- a/src/modules/m_cloaking.cpp +++ b/src/modules/m_cloaking.cpp @@ -223,7 +223,7 @@ class ModuleCloaking : public Module size_t hop1, hop2, hop3; size_t len1, len2; std::string rv; - if (ip.sa.sa_family == AF_INET6) + if (ip.family() == AF_INET6) { bindata = std::string((const char*)ip.in6.sin6_addr.s6_addr, 16); hop1 = 8; @@ -267,7 +267,7 @@ class ModuleCloaking : public Module } else { - if (ip.sa.sa_family == AF_INET6) + if (ip.family() == AF_INET6) { rv.append(InspIRCd::Format(".%02x%02x.%02x%02x%s", ip.in6.sin6_addr.s6_addr[2], ip.in6.sin6_addr.s6_addr[3], -- cgit v1.3.1-10-gc9f91