diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2004-06-09 14:39:33 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2004-06-09 14:39:33 +0000 |
commit | 3e638c84c0fbbaed5f6fecad0d96195343c40375 (patch) | |
tree | 22170ab79ba0d006343e074382589f4571f68013 /ext/gmp | |
parent | ccc580f408c5f3fc09e95318a7e2a4e816d7e986 (diff) | |
download | php-git-3e638c84c0fbbaed5f6fecad0d96195343c40375.tar.gz |
Fixed bug #28525 (gmp_powm() does not work with hexadecimal string modulo
represented as a string).
Patch by: pickett at sumu dot org
Diffstat (limited to 'ext/gmp')
-rw-r--r-- | ext/gmp/gmp.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c index 08633ceba6..f41b4063e3 100644 --- a/ext/gmp/gmp.c +++ b/ext/gmp/gmp.c @@ -842,8 +842,7 @@ ZEND_FUNCTION(gmp_powm) } FETCH_GMP_ZVAL(gmpnum_mod, mod_arg); - convert_to_long_ex(mod_arg); - if (!Z_LVAL_PP(mod_arg)) { + if (!mpz_cmp_ui(*gmpnum_mod, 0)) { RETURN_FALSE; } |