mirror of
https://github.com/php/php-src.git
synced 2024-11-27 11:53:33 +08:00
a375d54785
Cf. PR #6787. Closes GH-6994.
18 lines
361 B
PHP
18 lines
361 B
PHP
--TEST--
|
|
Bug #72494 (imagecropauto out-of-bounds access)
|
|
--EXTENSIONS--
|
|
gd
|
|
--FILE--
|
|
<?php
|
|
require __DIR__ . '/func.inc';
|
|
|
|
$im = imagecreate(10,10);
|
|
|
|
trycatch_dump(
|
|
fn() => imagecropauto($im, IMG_CROP_THRESHOLD, 0, 1337)
|
|
);
|
|
|
|
?>
|
|
--EXPECT--
|
|
!! [ValueError] imagecropauto(): Argument #4 ($color) must be greater than or equal to 0 when using the threshold mode
|