EAP: Fix possible memory leak in eap_ttls_process_decrypted()
In case eap_peer_tls_encrypt() fails in eap_ttls_process_decrypted(), free resp memory. Signed-off-by: Ben Rosenfeld <ben.rosenfeld@intel.com>
This commit is contained in:
parent
b760e64276
commit
9bd0273931
1 changed files with 1 additions and 0 deletions
|
@ -995,6 +995,7 @@ static int eap_ttls_encrypt_response(struct eap_sm *sm,
|
|||
resp, out_data)) {
|
||||
wpa_printf(MSG_INFO, "EAP-TTLS: Failed to encrypt a Phase 2 "
|
||||
"frame");
|
||||
wpabuf_free(resp);
|
||||
return -1;
|
||||
}
|
||||
wpabuf_free(resp);
|
||||
|
|
Loading…
Reference in a new issue