EAP-IKEV2 server: Fix invalid memory freeing operation
wpabuf needs to be freed with wpabuf_free(), not os_free(). Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
62cab3b737
commit
9288e6625b
1 changed files with 1 additions and 1 deletions
|
@ -990,7 +990,7 @@ static int ikev2_build_kei(struct ikev2_initiator_data *data,
|
||||||
*/
|
*/
|
||||||
wpabuf_put(msg, data->dh->prime_len - wpabuf_len(pv));
|
wpabuf_put(msg, data->dh->prime_len - wpabuf_len(pv));
|
||||||
wpabuf_put_buf(msg, pv);
|
wpabuf_put_buf(msg, pv);
|
||||||
os_free(pv);
|
wpabuf_free(pv);
|
||||||
|
|
||||||
plen = (u8 *) wpabuf_put(msg, 0) - (u8 *) phdr;
|
plen = (u8 *) wpabuf_put(msg, 0) - (u8 *) phdr;
|
||||||
WPA_PUT_BE16(phdr->payload_length, plen);
|
WPA_PUT_BE16(phdr->payload_length, plen);
|
||||||
|
|
Loading…
Reference in a new issue