str_token() can return NULL for the name if the remaining token contains
only the delimiter. Fix this to avoid NULL pointer dereference with a
corner case of an invalid value used in the configuration.
Fixes: ec5c39a5574d ("AP: Allow identifying which passphrase station used with wpa_psk_file")
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
break;
context2 = NULL;
name = str_token(token, "=", &context2);
+ if (!name)
+ break;
value = str_token(token, "", &context2);
if (!value)
value = "";