RSN IBSS: Fix segfault on error path
If wpa_init() fails, wpa_deinit(NULL) must not be called to avoid hitting a NULL pointer dereference. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
2fca1f67cf
commit
6f416c7867
1 changed files with 2 additions and 1 deletions
|
@ -697,6 +697,7 @@ void ibss_rsn_deinit(struct ibss_rsn *ibss_rsn)
|
||||||
ibss_rsn_free(prev);
|
ibss_rsn_free(prev);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ibss_rsn->auth_group)
|
||||||
wpa_deinit(ibss_rsn->auth_group);
|
wpa_deinit(ibss_rsn->auth_group);
|
||||||
os_free(ibss_rsn);
|
os_free(ibss_rsn);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue