]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
wifi-scripts: return the interface-creation result from wdev_add
authorFelix Fietkau <nbd@nbd.name>
Fri, 10 Jul 2026 12:44:07 +0000 (14:44 +0200)
committerFelix Fietkau <nbd@nbd.name>
Thu, 16 Jul 2026 09:50:22 +0000 (11:50 +0200)
wdev_add() dropped the wdev_create() result, so every caller's error check
was dead and an nl80211 NEW_INTERFACE failure was silently ignored (hostapd
and wpa_supplicant then proceeded on a missing netdev with stale MLD
bookkeeping). Return the result.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
package/network/config/wifi-scripts/files/usr/share/hostap/common.uc

index f801c4940c2b76947d34705e80305463b609768a..a3b4ae8248bea3ffbc1adefb88cd78bdafc718ec 100644 (file)
@@ -298,8 +298,7 @@ const phy_proto = {
        },
 
        wdev_add: function(name, data) {
-               let phydev = this;
-               wdev_create(this.phy, name, {
+               return wdev_create(this.phy, name, {
                        ...data,
                        radio: this.radio,
                });