提交 6b521df3 编写于 作者: B Bodo Möller

Looks like another memory leak ...

上级 72e2ffee
...@@ -930,6 +930,7 @@ static int ssl3_get_key_exchange(SSL *s) ...@@ -930,6 +930,7 @@ static int ssl3_get_key_exchange(SSL *s)
goto err; goto err;
} }
s->session->sess_cert->peer_rsa_tmp=rsa; s->session->sess_cert->peer_rsa_tmp=rsa;
rsa=NULL;
} }
else else
#endif #endif
...@@ -1114,6 +1115,14 @@ f_err: ...@@ -1114,6 +1115,14 @@ f_err:
ssl3_send_alert(s,SSL3_AL_FATAL,al); ssl3_send_alert(s,SSL3_AL_FATAL,al);
err: err:
EVP_PKEY_free(pkey); EVP_PKEY_free(pkey);
#ifndef NO_RSA
if (rsa != NULL)
RSA_free(rsa);
#endif
#ifndef NO_DH
if (dh != NULL)
DH_free(dh);
#endif
return(-1); return(-1);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册