From: Roy Marples Date: Tue, 11 Mar 2025 12:02:41 +0000 (+0000) Subject: DHCP6: Don't reboot when not doing DHCPv6 X-Git-Tag: v10.2.3~18 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e8b2c8f29aa9d9ceaa14a7951935c662dc8af307;p=thirdparty%2Fdhcpcd.git DHCP6: Don't reboot when not doing DHCPv6 For #437 and #478. --- diff --git a/src/dhcpcd.c b/src/dhcpcd.c index 1b1e1b2f..4835fef0 100644 --- a/src/dhcpcd.c +++ b/src/dhcpcd.c @@ -1316,10 +1316,12 @@ if_reboot(struct interface *ifp, int argc, char **argv) script_runreason(ifp, "RECONFIGURE"); dhcpcd_initstate1(ifp, argc, argv, 0); #ifdef INET - dhcp_reboot_newopts(ifp, oldopts); + if (ifp->options->options & DHCPCD_DHCP) + dhcp_reboot_newopts(ifp, oldopts); #endif #ifdef DHCP6 - dhcp6_reboot(ifp); + if (ifp->options->options & DHCPCD_DHCP6) + dhcp6_reboot(ifp); #endif dhcpcd_prestartinterface(ifp); }