BigInteger: fix PHP7 error

$x = gmp_init(6); empty($x); demonstrates the problem
This commit is contained in:
terrafrost 2015-09-13 19:13:31 -05:00
parent 71d7108d9a
commit 833da775b6

View File

@ -3557,7 +3557,7 @@ class Math_BigInteger
switch (MATH_BIGINTEGER_MODE) { switch (MATH_BIGINTEGER_MODE) {
case MATH_BIGINTEGER_MODE_GMP: case MATH_BIGINTEGER_MODE_GMP:
if (!empty($result->bitmask->value)) { if ($this->bitmask !== false) {
$result->value = gmp_and($result->value, $result->bitmask->value); $result->value = gmp_and($result->value, $result->bitmask->value);
} }