summaryrefslogtreecommitdiffhomepage
path: root/wireless.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-12-02 14:49:10 +0100
committerFelix Fietkau <nbd@openwrt.org>2015-12-02 14:49:59 +0100
commit988b5f74dab89f285e3bb59196b4cc880cfa51c7 (patch)
treee4d01ca296440b1328e41cc5e0570c9c86a772f8 /wireless.c
parent48c0fbee548206058c399a73a80178cdcfec3fc7 (diff)
wireless: call wireless_interface_handle_link before updating vif config
If the network changes, we need to remove the vif from the old network before we lose access to the previous state Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Diffstat (limited to 'wireless.c')
-rw-r--r--wireless.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/wireless.c b/wireless.c
index 1f96089..34dd328 100644
--- a/wireless.c
+++ b/wireless.c
@@ -591,6 +591,7 @@ vif_update(struct vlist_tree *tree, struct vlist_node *node_new,
}
D(WIRELESS, "Update wireless interface %s on device %s\n", vif_new->name, wdev->name);
+ wireless_interface_handle_link(vif_old, false);
free(vif_old->config);
vif_old->config = blob_memdup(vif_new->config);
vif_old->isolate = vif_new->isolate;