tls: Fix an invalid free on CBC encryption failure

This commit is contained in:
Martin Willi
2014-10-15 14:26:03 +02:00
parent 867d04b72e
commit cbb86a2df3
-1
View File
@@ -91,7 +91,6 @@ METHOD(tls_aead_t, encrypt, bool,
/* encrypt inline */ /* encrypt inline */
if (!this->crypter->encrypt(this->crypter, *data, iv, NULL)) if (!this->crypter->encrypt(this->crypter, *data, iv, NULL))
{ {
free(data->ptr);
return FALSE; return FALSE;
} }
/* prepend IV */ /* prepend IV */