diff options
author | Stanislav Malyshev <stas@php.net> | 2016-04-26 23:04:29 -0700 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2016-04-26 23:04:29 -0700 |
commit | a32e143d4eb185f9b666ef1cd93761b2baafec28 (patch) | |
tree | 59965dce45f544cc4c3f41f7617da66f10c3910c /ext/gmp | |
parent | ccc12efa32f855e6057cb9b7e1e45afe08503a00 (diff) | |
download | php-git-a32e143d4eb185f9b666ef1cd93761b2baafec28.tar.gz |
fix build
Diffstat (limited to 'ext/gmp')
-rw-r--r-- | ext/gmp/gmp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c index 928ec26005..a1e15899c9 100644 --- a/ext/gmp/gmp.c +++ b/ext/gmp/gmp.c @@ -1145,7 +1145,7 @@ ZEND_FUNCTION(gmp_export) size_t bits_per_word = size * 8; size_t count = (mpz_sizeinbase(gmpnumber, 2) + bits_per_word - 1) / bits_per_word; - zend_string *out_string = zend_string_safe_alloc(count, out_len, 0, 0); + zend_string *out_string = zend_string_safe_alloc(count, size, 0, 0); mpz_export(ZSTR_VAL(out_string), NULL, order, size, endian, 0, gmpnumber); ZSTR_VAL(out_string)[ZSTR_LEN(out_string)] = '\0'; |