Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Use gmp_pow overload to avoid php bug GH-16870 #29

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

famoser
Copy link

@famoser famoser commented Nov 26, 2024

In the newest php minor releases there is an issue with gmp_pow that only accepts very small values: php/php-src#16870 Concretely, for reasonably big numbers, the execution fails with Uncaught ValueError: base and exponent overflow According to the changelog, this change is in 8.3.14 and 8.2.26.

However, according to a comment in the bug thread, it is sufficient to replace gmp_pow with ** to avoid triggering the bug.

I've applied this patch to this project, and indeed the tests pass.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant