]> granicus.if.org Git - php/commitdiff
Merge branch 'PHP-7.0' into PHP-7.1
authorAnatol Belski <ab@php.net>
Sat, 8 Oct 2016 17:28:21 +0000 (19:28 +0200)
committerAnatol Belski <ab@php.net>
Sat, 8 Oct 2016 17:28:21 +0000 (19:28 +0200)
* PHP-7.0:
  fix leak

1  2 
ext/mcrypt/mcrypt.c

index c2c60c2b3cdcb964001f86a9bcf0a70297266c8d,e7bdd43c9bb2c449e1e6da065babd96ddf277cb8..24dd26e0a69e17d93419bbb8778944da759432f9
@@@ -1299,7 -1299,8 +1299,8 @@@ static void php_mcrypt_do_crypt(char* c
        }
  
        if (mcrypt_generic_init(td, (void *) key, (int)key_len, (void *) iv) < 0) {
 -              php_error_docref(NULL, E_RECOVERABLE_ERROR, "Mcrypt initialisation failed");
+               efree(data_s);
 +              zend_throw_error(NULL, "Mcrypt initialisation failed");
                mcrypt_module_close(td);
                RETURN_FALSE;
        }