-
Notifications
You must be signed in to change notification settings - Fork 7.8k
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
imagescale(): Argument #3 ($height) must be between 1 and 2147483647 #17703
Comments
That looks like a php issue. transferring. |
@valeriiabykovets would you mind sharing your use case to be able to reproduce ? |
Probably a negative value flipped the image? Just a guess |
So gdImageSx might need to return 0 in this case with height set to -1. |
Also I think that -2 flips and makes the height twice as much. So any value except 0 should probably be allowed. |
I found that this error happened because of scaling the file 400x1. While previously the method returned false in such cases, since php 8.4.0 it throws error. |
Line 3959 in dc7161c
If both width and height are negative, we should probably throw a ValueError with a suitable message. Not sure if the current behavior qualifies as bug, though ( |
…lues. Throwing a ValueError in this particular case.
…lues. Throwing a ValueError in this particular case.
imagescale(): Argument php/doc-en#3 ($height) must be between 1 and 2147483647. -1 is no longer allowed?
From manual page: https://php.net/function.imagescale
The text was updated successfully, but these errors were encountered: