summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorHans Dedecker <dedeckeh@gmail.com>2014-05-07 09:19:08 +0000
committerSteven Barth <steven@midlink.org>2014-05-09 15:50:33 +0200
commit4b7662c5841214c105a174fdc9ab9fac870abab9 (patch)
tree08df34f086891b2836082dfdf47730d7888926e6
parent5dc8988377cccbdd9a520f21000d2cea1fc76f7f (diff)
netifd: Check interface state only when main device is set during interface_change_config
Fixes a regression issue introduced by commit d2a33f3f0fe704e4396fa2ada08401cb955ba7cb for device less protocol handlers. An active interface using a deviceless protocol handler will be be teared down when the interface config is checked upon an update as the interface link and enabled parameters are unset as no underlying device is present (eg tunnel interfaces) Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
-rw-r--r--interface.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/interface.c b/interface.c
index 95e1ee8..a4d7b8d 100644
--- a/interface.c
+++ b/interface.c
@@ -1020,7 +1020,8 @@ interface_change_config(struct interface *if_old, struct interface *if_new)
}
interface_write_resolv_conf();
- interface_check_state(if_old);
+ if (if_old->main_dev.dev)
+ interface_check_state(if_old);
out:
if_new->config = NULL;