LocalIP (BSD): fix building

This commit is contained in:
李通洲
2025-08-07 20:18:52 +08:00
parent a84c4dc1f4
commit be11013ae2
2 changed files with 1 additions and 2 deletions
-1
View File
@@ -7,7 +7,6 @@
#include <net/if_dl.h>
#include <net/route.h>
#include <netinet/in.h>
#include <netinet6/in6.h>
#include <sys/socket.h>
#include <sys/sysctl.h>
+1 -1
View File
@@ -157,7 +157,7 @@ static bool isIPv6AddressPreferred(const char* ifname, struct sockaddr_in6* addr
if (ioctl(sockfd, SIOCGIFAFLAG_IN6, &ifr6) != 0)
return true;
return !(ifr6.ifr_flags & IN6_IFF_DEPRECATED) && !(ifr6.ifr_flags & IN6_IFF_TEMPORARY);
return !(ifr6.ifr_ifru.ifru_flags6 & IN6_IFF_DEPRECATED) && !(ifr6.ifr_ifru.ifru_flags6 & IN6_IFF_TEMPORARY);
#elif __linux__
FF_UNUSED(ifname);