]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Stop setting RA override becuse it only makes sense when we want the kernel
authorRoy Marples <roy@marples.name>
Thu, 18 Aug 2016 14:38:49 +0000 (14:38 +0000)
committerRoy Marples <roy@marples.name>
Thu, 18 Aug 2016 14:38:49 +0000 (14:38 +0000)
to listen to RA's which we don't want.

if-bsd.c

index b15dc7854a564a909c253c3a1b6ea155bfe12325..70904f32694736b5aadcf05ce71e016c73a96323 100644 (file)
--- a/if-bsd.c
+++ b/if-bsd.c
@@ -1687,10 +1687,6 @@ _if_checkipv6(int s, struct dhcpcd_ctx *ctx,
        int ra;
 
        if (ifp) {
-#ifdef ND6_IFF_OVERRIDE_RTADV
-               int override;
-#endif
-
 #ifdef ND6_IFF_AUTO_LINKLOCAL
                if (own) {
                        int all;
@@ -1728,24 +1724,6 @@ _if_checkipv6(int s, struct dhcpcd_ctx *ctx,
                }
 #endif
 
-#ifdef ND6_IFF_OVERRIDE_RTADV
-               override = get_if_nd6_flag(s, ifp, ND6_IFF_OVERRIDE_RTADV);
-               if (override == -1)
-                       logger(ifp->ctx, LOG_ERR,
-                           "%s: get_if_nd6_flag: ND6_IFF_OVERRIDE_RTADV: %m",
-                           ifp->name);
-               else if (override == 0 && own) {
-                       if (set_if_nd6_flag(s, ifp, ND6_IFF_OVERRIDE_RTADV)
-                           == -1)
-                               logger(ifp->ctx, LOG_ERR,
-                                   "%s: set_if_nd6_flag: "
-                                   "ND6_IFF_OVERRIDE_RTADV: %m",
-                                   ifp->name);
-                       else
-                               override = 1;
-               }
-#endif
-
 #ifdef ND6_IFF_ACCEPT_RTADV
                ra = get_if_nd6_flag(s, ifp, ND6_IFF_ACCEPT_RTADV);
                if (ra == -1)
@@ -1799,10 +1777,6 @@ _if_checkipv6(int s, struct dhcpcd_ctx *ctx,
 #endif
 
 #ifdef ND6_IFF_ACCEPT_RTADV
-#ifdef ND6_IFF_OVERRIDE_RTADV
-               if (override == 0 && ra)
-                       return ctx->ra_global;
-#endif
                return ra;
 #else
                return ctx->ra_global;