Fix memory leak in KeyShare using ECC and not fast math

This commit is contained in:
Sean Parkinson
2018-08-27 10:50:57 +10:00
parent 205088d1bc
commit 24694ef7b0

View File

@ -6578,6 +6578,7 @@ static int TLSX_KeyShare_ProcessEcc(WOLFSSL* ssl, KeyShareEntry* keyShareEntry)
);
#endif
wc_ecc_free(ssl->peerEccKey);
XFREE(ssl->peerEccKey, ssl->heap, DYNAMIC_TYPE_ECC);
ssl->peerEccKey = NULL;
wc_ecc_free((ecc_key*)(keyShareEntry->key));