xref: /PHP-7.2/ext/gd/tests/bug72512.phpt (revision f1d7e3ca)
1--TEST--
2Bug #19366 (gdimagefill() function crashes (fixed in bundled libgd))
3--SKIPIF--
4<?php
5	if (!extension_loaded('gd')) die("skip gd extension not available\n");
6	if (!GD_BUNDLED && version_compare(GD_VERSION, '2.2.2', '<')) {
7		die("skip test requires GD 2.2.2 or higher");
8	}
9?>
10--FILE--
11<?php
12$img = imagecreatetruecolor(100, 100);
13imagecolortransparent($img, -1000000);
14imagetruecolortopalette($img, TRUE, 3);
15imagecolortransparent($img, 9);
16echo "OK";
17?>
18--EXPECT--
19OK
20