]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Revert e92e049e as Linux marks autoconf addresses as manage
authorRoy Marples <roy@marples.name>
Tue, 12 Sep 2017 10:35:01 +0000 (11:35 +0100)
committerRoy Marples <roy@marples.name>
Tue, 12 Sep 2017 10:35:01 +0000 (11:35 +0100)
temporary addresses from this address.

src/ipv6.h

index 0a585f492003ac035bc23bcb46c4332e146ade15..8fca8a71f737b08316999982e421b85722117404 100644 (file)
 #  undef IPV6_POLLADDRFLAG
 #endif
 
-#ifdef __linux__
-   /* Match Linux defines to BSD */
-#  ifdef IFA_F_TEMPORARY
-#    define IN6_IFF_TEMPORARY  IFA_F_TEMPORARY
-#  endif
-#  ifdef IFA_F_OPTIMISTIC
-#    define IN6_IFF_TENTATIVE  (IFA_F_TENTATIVE | IFA_F_OPTIMISTIC)
-#  else
-#    define IN6_IFF_TENTATIVE   (IFA_F_TENTATIVE | 0x04)
-#  endif
-#  ifdef IF_F_DADFAILED
-#    define IN6_IFF_DUPLICATED IFA_F_DADFAILED
-#  else
-#    define IN6_IFF_DUPLICATED 0x08
-#  endif
-#  define IN6_IFF_DETACHED     0
-#endif
-
 #ifdef __sun
    /* Solaris lacks these defines.
     * While it supports DaD, to seems to only expose IFF_DUPLICATE
  * Some BSDs do not allow userland to set temporary addresses.
  * Linux-3.18 allows the marking of addresses from which to manage temp addrs.
  */
-#ifdef IN6_IFF_TEMPORARY
+#if defined(IN6_IFF_TEMPORARY) && !defined(__linux__)
 #define        IPV6_MANAGETEMPADDR
 #endif
 
+#ifdef __linux__
+   /* Match Linux defines to BSD */
+#  ifdef IFA_F_TEMPORARY
+#    define IN6_IFF_TEMPORARY  IFA_F_TEMPORARY
+#  endif
+#  ifdef IFA_F_OPTIMISTIC
+#    define IN6_IFF_TENTATIVE  (IFA_F_TENTATIVE | IFA_F_OPTIMISTIC)
+#  else
+#    define IN6_IFF_TENTATIVE   (IFA_F_TENTATIVE | 0x04)
+#  endif
+#  ifdef IF_F_DADFAILED
+#    define IN6_IFF_DUPLICATED IFA_F_DADFAILED
+#  else
+#    define IN6_IFF_DUPLICATED 0x08
+#  endif
+#  define IN6_IFF_DETACHED     0
+#endif
+
 TAILQ_HEAD(ipv6_addrhead, ipv6_addr);
 struct ipv6_addr {
        TAILQ_ENTRY(ipv6_addr) next;