Skip to content

Commit dda5457

Browse files
committed
[nrf noup] zephyr: Fix reason code for locally generated disconnection
fixup! [nrf noup] zephyr: Implement connect and disconnect events to Zephyr In case a use issues a disconnect for some reason, it will still send IEEE 802.11 reason code 3, which will show up as a Failure (non-zero status) in Zephyr, this should only be applicable if AP sends de-authentication with reason code as "3". Fix locally generated case to return success (the enum should also be renamed from "unspecified" to "local", but that will be handled in another PR). Fixes SHEL-2561. Signed-off-by: Chaitanya Tata <[email protected]>
1 parent 1bdd1e9 commit dda5457

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

wpa_supplicant/events.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3599,7 +3599,7 @@ static void wpa_supplicant_event_disassoc(struct wpa_supplicant *wpa_s,
35993599
MAC2STR(bssid), reason_code,
36003600
locally_generated ? " locally_generated=1" : "");
36013601
#ifdef CONFIG_ZEPHYR
3602-
send_wifi_mgmt_disc_event(wpa_s, reason_code);
3602+
send_wifi_mgmt_disc_event(wpa_s, locally_generated ? 0 : reason_code);
36033603
#endif /* CONFIG_ZEPHYR */
36043604
}
36053605
}

0 commit comments

Comments
 (0)