Skip to content

Commit 7dd4779

Browse files
committed
wifi-scripts: fix disabled vif tracking using wrong dictionary key
wdev_update_disabled_vifs() indexed the disabled_vifs map with the wdev object instead of the vif name. The map is read back via disabled_vifs[vif.name], so disabled vifs were never matched, and coercing the wdev object into a string key triggered an infinite escaping loop in ucv_to_string_json_encoded() during state output, causing OOM on reboot. Suggested-by: Shayne Chen (陳軒丞) <Shayne.Chen@mediatek.com> Reported-by: Michael-cy Lee (李峻宇) <Michael-cy.Lee@mediatek.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
1 parent 55efd11 commit 7dd4779

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

package/network/config/wifi-scripts/files/lib/netifd/wireless-device.uc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ function wdev_update_disabled_vifs(wdev)
353353

354354
let name = vif.name;
355355
if (enabled == false)
356-
disabled[wdev] = true;
356+
disabled[name] = true;
357357
else if (ifindex != cache[name])
358358
changed = true;
359359

0 commit comments

Comments
 (0)