Skip to content

Commit c3f71bf

Browse files
Update examples/platform/silabs/efr32/wf200/host_if.cpp
Co-authored-by: Junior Martinez <67972863+jmartinez-silabs@users.noreply.github.com>
1 parent 09515b0 commit c3f71bf

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

examples/platform/silabs/efr32/wf200/host_if.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -737,6 +737,7 @@ int32_t wfx_get_ap_info(wfx_wifi_scan_result_t * ap)
737737
int32_t signal_strength;
738738

739739
ap->ssid_length = strnlen(ap_info.ssid, chip::min<size_t>(sizeof(ap_info.ssid), WFX_MAX_SSID_LENGTH));
740+
// ap->ssid is of size WFX_MAX_SSID_LENGTH+1, we are safe with the ap->ssid_length calculated above
740741
chip::Platform::CopyString(ap->ssid, ap->ssid_length + 1, ap_info.ssid); // +1 for null termination
741742
memcpy(ap->bssid, ap_info.bssid, sizeof(ap_info.bssid));
742743
ap->security = ap_info.security;

0 commit comments

Comments
 (0)