Add an explicit check for msg->channel_list != NULL instead of depending
on msg->channel_list_len > 0 implying that. This is to silence invalid
static analyzer reports.
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
&op_channel) < 0)
continue; /* cannot happen due to earlier check */
for (j = 0; j < msg->channel_list_len; j++) {
-
- if (op_channel != msg->channel_list[j])
+ if (!msg->channel_list ||
+ op_channel != msg->channel_list[j])
continue;
p2p->op_reg_class = op_class;