1--TEST-- 2Bug #72709 (imagesetstyle() causes OOB read for empty $styles) 3--EXTENSIONS-- 4gd 5--FILE-- 6<?php 7$im = imagecreatetruecolor(1, 1); 8 9try { 10 var_dump(imagesetstyle($im, array())); 11} 12catch (\Error $ex) { 13 echo $ex->getMessage() . "\n"; 14} 15 16imagesetpixel($im, 0, 0, IMG_COLOR_STYLED); 17imagedestroy($im); 18?> 19====DONE==== 20--EXPECT-- 21imagesetstyle(): Argument #2 ($style) cannot be empty 22====DONE==== 23