Make test code easier for static analyzers

The previous os_strncmp() calls have already verified that there is a
space in the string, so this os_strchr() call cannot really return NULL.
Anyway, make this easier for static analyzers to understand.

Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
This commit is contained in:
Jouni Malinen 2024-01-22 22:02:39 +02:00 committed by Jouni Malinen
parent c03377cf27
commit 5ae8838a06

View file

@ -11235,6 +11235,8 @@ static int wpas_ctrl_iface_pasn_driver(struct wpa_supplicant *wpa_s,
return -1;
pos = os_strchr(pos, ' ');
if (!pos)
return -1;
pos++;
while (hwaddr_aton(pos, addr) == 0) {
struct pasn_peer *peer;