summaryrefslogtreecommitdiff
path: root/net/ocserv/files/patch-src_main-ban.c
blob: 2a4446d29abbacd7f197b6d3beee86334bc6f119 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
--- src/main-ban.c.orig	2021-01-26 17:01:03 UTC
+++ src/main-ban.c
@@ -403,8 +403,8 @@ static bool test_local_ipv6(struct sockaddr_in6 * remo
 	unsigned index = 0;
 	
 	for (index = 0; index < 4; index ++) {
-		uint32_t l = local->sin6_addr.s6_addr32[index] & network->sin6_addr.s6_addr32[index];
-		uint32_t r = remote->sin6_addr.s6_addr32[index] & network->sin6_addr.s6_addr32[index];
+		uint32_t l = local->sin6_addr.__u6_addr.__u6_addr32[index] & network->sin6_addr.__u6_addr.__u6_addr32[index];
+		uint32_t r = remote->sin6_addr.__u6_addr.__u6_addr32[index] & network->sin6_addr.__u6_addr.__u6_addr32[index];
 		if (l != r) 
 			return false;
 	}
@@ -443,4 +443,4 @@ void if_address_cleanup(main_server_st * s)
 
 	s->if_addresses = NULL;
 	s->if_addresses_count = 0;
-}
\ No newline at end of file
+}