From 1bf627bb338ffe61e01bf7d6eeda4a6e18ccbeca Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Tue, 18 Oct 2011 20:42:48 +0200 Subject: [PATCH] on proto event IFPEV_DOWN, do not attempt to bring up interfaces that are no longer available --- interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interface.c b/interface.c index 7c8a0c2..7837274 100644 --- a/interface.c +++ b/interface.c @@ -279,10 +279,10 @@ interface_proto_cb(struct interface_proto_state *state, enum interface_proto_eve system_flush_routes(); mark_interface_down(iface); interface_handle_config_change(iface); - if (iface->autostart) - __interface_set_up(iface); if (iface->l3_dev->dev) device_release(iface->l3_dev); + if (iface->autostart && iface->available) + __interface_set_up(iface); break; case IFPEV_LINK_LOST: if (iface->state != IFS_UP) -- 2.30.2