diff options
author | Felix Fietkau <nbd@openwrt.org> | 2012-06-04 20:19:53 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2012-06-04 20:19:53 +0200 |
commit | 3bd580e340d2075194cb353da32e10393b006c55 (patch) | |
tree | 42d9b81dd24b1fa4c44f8adfbf30c1b1239c2812 | |
parent | 56f3e9c817a8074ee8928e6a4b62320ffabcdb8b (diff) |
interface: clean up after hotplug interfaces are removed
-rw-r--r-- | interface.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/interface.c b/interface.c index 3215f49..01dabad 100644 --- a/interface.c +++ b/interface.c @@ -215,6 +215,8 @@ interface_cb(struct device_user *dep, enum device_event ev) } interface_set_available(iface, new_state); + if (!new_state && dep->dev->external) + interface_set_main_dev(iface, NULL); } void |