openssl encrypt: fixed a leak

fixes CID 402977
This commit is contained in:
Martin Pulec
2022-11-21 14:52:52 +01:00
parent cf9d8e8bf2
commit 387291a7d4

View File

@@ -130,6 +130,7 @@ static int openssl_encrypt_init(struct openssl_encrypt **state, const char *pass
s->cipher = get_cipher(mode);
if (s->cipher == NULL) {
log_msg(LOG_LEVEL_ERROR, MOD_NAME "Cipher %d not available!\n", (int) mode);
free(s);
return -1;
}