mirror of
https://github.com/php/php-src.git
synced 2024-11-27 11:53:33 +08:00
23a55babb4
close GH-14598
23 lines
452 B
PHP
23 lines
452 B
PHP
--TEST--
|
|
Bug #73957 (signed integer conversion in imagescale())
|
|
--EXTENSIONS--
|
|
gd
|
|
--SKIPIF--
|
|
<?php
|
|
if (PHP_INT_SIZE != 8) die('skip this test is for 64bit platforms only');
|
|
?>
|
|
--FILE--
|
|
<?php
|
|
$im = imagecreate(8, 8);
|
|
|
|
try {
|
|
$im = imagescale($im, 0x100000001, 1);
|
|
// which is not supposed to happen
|
|
var_dump(imagesx($im));
|
|
} catch (\ValueError $e) {
|
|
echo $e->getMessage();
|
|
}
|
|
?>
|
|
--EXPECTF--
|
|
imagescale(): Argument #2 ($width) must be between 1 and %d
|