}
static void
-finish_config(struct if_options *ifo, const char *ifname)
+finish_config(struct if_options *ifo)
{
/* Terminate the encapsulated options */
ifo->vendor[0]++;
ifo->vendor[ifo->vendor[0]] = DHO_END;
}
+}
#ifdef INET6
+static void
+finish_config6(struct if_options *ifo, const char *ifname)
+{
+
if (!(ifo->options & DHCPCD_IPV6))
ifo->options &= ~DHCPCD_IPV6RS;
ifo->iaid->sla_len = 0;
}
}
-#endif
}
+#endif
struct if_options *
read_config(const char *file,
ifo = NULL;
}
- finish_config(ifo, ifname);
+ finish_config(ifo);
+#ifdef INET6
+ finish_config6(ifo, ifname);
+#endif
return ifo;
}
break;
}
- finish_config(ifo, NULL);
+ finish_config(ifo);
+#ifdef INET6
+ finish_config6(ifo, NULL);
+#endif
return r;
}