commit 28c8b664e471df9adbba5f2b8598b4e95ae36f4b
parent 0f73eff96a6480d7791b54843238f5c16de6453d
Author: Florian Eckert <fe@dev.tdt.de>
Date: Fri, 17 Mar 2017 11:06:24 +0100
net/mwan3: fix hotplug on ACTION ifdown
On dynamic interface proto (dhcp/pppoe) the hotplug will not execude (exit 9)
because the gateway is already released. The check will now only be made
on a ifup ACTION event.
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
Diffstat:
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/net/mwan3/files/etc/hotplug.d/iface/15-mwan3 b/net/mwan3/files/etc/hotplug.d/iface/15-mwan3
@@ -30,7 +30,9 @@ elif [ "$family" == "ipv6" ]; then
network_get_gateway6 gateway $INTERFACE
fi
-[ -n "$gateway" ] || exit 9
+if [ "$ACTION" == "ifup" ]; then
+ [ -n "$gateway" ] || exit 9
+fi
$LOG notice "$ACTION interface $INTERFACE (${DEVICE:-unknown})"