Coverity CID 3491, 3492: Plug memory leaks.

This commit is contained in:
christos 2006-05-21 17:32:23 +00:00
parent 555b8edb2d
commit 884667d071
1 changed files with 2 additions and 0 deletions

View File

@ -141,6 +141,7 @@ static void * eap_peap_init(struct eap_sm *sm)
_methods = realloc(methods, num_methods);
if (_methods == NULL) {
free(methods);
free(buf);
eap_peap_deinit(sm, data);
return NULL;
}
@ -723,6 +724,7 @@ static u8 * eap_peap_process(struct eap_sm *sm, void *priv,
}
if (res == 1) {
free(resp);
return eap_tls_build_ack(&data->ssl, respDataLen, id,
EAP_TYPE_PEAP, data->peap_version);
}