diff options
Diffstat (limited to 'ext/gmp/gmp.c')
| -rw-r--r-- | ext/gmp/gmp.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c index 3b58212902..7eb9eef494 100644 --- a/ext/gmp/gmp.c +++ b/ext/gmp/gmp.c @@ -1451,10 +1451,9 @@ ZEND_FUNCTION(gmp_powm) FETCH_GMP_ZVAL_DEP_DEP(gmpnum_mod, mod_arg, temp_mod, temp_exp, temp_base); if (!mpz_cmp_ui(gmpnum_mod, 0)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Modulus may not be zero"); FREE_GMP_TEMP(temp_base); - if (use_ui) { - FREE_GMP_TEMP(temp_exp); - } + FREE_GMP_TEMP(temp_exp); FREE_GMP_TEMP(temp_mod); RETURN_FALSE; } |
