summaryrefslogtreecommitdiffstats
path: root/src/ipv6.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-04-09 16:19:07 +0000
committerRoy Marples <roy@marples.name>2020-04-09 16:19:07 +0000
commitdb58572fd54a12ee5959d86e2b77b0d3621f9adf (patch)
tree640a40dee09bce57193f5ec50d255bcb16e19122 /src/ipv6.c
parentd839b2ed96bbcd37362a7c7385c4dfe6d161909b (diff)
downloaddhcpcd-db58572fd54a12ee5959d86e2b77b0d3621f9adf.tar.xz
Linux: Note router preference when adding routes
This appears to just be cosmetic.
Diffstat (limited to 'src/ipv6.c')
-rw-r--r--src/ipv6.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/ipv6.c b/src/ipv6.c
index ede87c3d..570879ae 100644
--- a/src/ipv6.c
+++ b/src/ipv6.c
@@ -2253,6 +2253,9 @@ inet6_raroutes(rb_tree_t *routes, struct dhcpcd_ctx *ctx)
rt = inet6_makeprefix(rap->iface, rap, addr);
if (rt) {
rt->rt_dflags |= RTDF_RA;
+#ifdef HAVE_ROUTE_PREF
+ rt->rt_pref = ipv6nd_rtpref(rap);
+#endif
rt_proto_add(routes, rt);
}
}
@@ -2264,6 +2267,9 @@ inet6_raroutes(rb_tree_t *routes, struct dhcpcd_ctx *ctx)
if (rt == NULL)
continue;
rt->rt_dflags |= RTDF_RA;
+#ifdef HAVE_ROUTE_PREF
+ rt->rt_pref = ipv6nd_rtpref(rap);
+#endif
rt_proto_add(routes, rt);
}
return 0;