From 3c5742ebd735d03468048edbca434769dffec8f4 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Sat, 8 Oct 2016 19:07:35 +0200 Subject: fix leak --- ext/mcrypt/mcrypt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index 7539d9e53f..66382aeb7c 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -1310,6 +1310,7 @@ static void php_mcrypt_do_crypt(char* cipher, const char *key, int key_len, cons } if (mcrypt_generic_init(td, (void *) key, key_len, (void *) iv) < 0) { + efree(data_s); php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Mcrypt initialisation failed"); mcrypt_module_close(td); RETURN_FALSE; -- cgit v1.2.1