Skip to content

Fix: Determine start index of nearby networks more robustly to prevent from duplicate ids for known and nearby networks - #2013

Merged
billz merged 2 commits into
RaspAP:masterfrom
meandthemachine:fix/duplicate-ids-for-nearby-networks
Nov 26, 2025
Merged

Fix: Determine start index of nearby networks more robustly to prevent from duplicate ids for known and nearby networks#2013
billz merged 2 commits into
RaspAP:masterfrom
meandthemachine:fix/duplicate-ids-for-nearby-networks

Conversation

@meandthemachine

Copy link
Copy Markdown
Contributor

Resolves #2003.
Also cleanup of unused local variable.

Resolves RaspAP#2003:
Unless we examine its source code, we don't exactly know if `wpa_cli ... list_networks` always assigns network ids in the order the known networks are listed in the configuration file. Therefore, we should not assume it to be this way and instead, we should make the code capable of handling all scenarios (in-synch as well as async) in a robust way.
The  assigned/incremented value is/was never used anywhere else in the loop.
@meandthemachine meandthemachine changed the title Determine start index of nearby networks more robustly to prevent from duplicate ids for known and nearby networks Fix: Determine start index of nearby networks more robustly to prevent from duplicate ids for known and nearby networks Nov 24, 2025
@billz
billz merged commit 789cc4f into RaspAP:master Nov 26, 2025
3 checks passed
@billz

billz commented Nov 26, 2025

Copy link
Copy Markdown
Member

@meandthemachine tested & validated. many thanks for the PR

@meandthemachine

Copy link
Copy Markdown
Contributor Author

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Duplicate indices in WiFi client page prevent from adding a nearby WiFi network

2 participants