From 988b5f74dab89f285e3bb59196b4cc880cfa51c7 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 2 Dec 2015 14:49:10 +0100 Subject: [PATCH] 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 --- wireless.c | 1 + 1 file changed, 1 insertion(+) 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; -- 2.30.2