-
Notifications
You must be signed in to change notification settings - Fork 7.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #76041: null pointer access crashed php
We must not draw anti-aliased lines on palette images, because that is not supported by `gdImageSetAAPixelColor()` and it wouldn't make much sense to support it, due to the limitation to at most 256 colors.
- Loading branch information
Showing
3 changed files
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--TEST-- | ||
Bug #76041 (null pointer access crashed php) | ||
--SKIPIF-- | ||
<?php | ||
if (!extension_loaded('gd')) die('skip gd extension not available'); | ||
?> | ||
--FILE-- | ||
<?php | ||
$im=imagecreate(100, 100); | ||
imageantialias($im, true); | ||
imageline($im, 0, 0, 10, 10, 0xffffff); | ||
?> | ||
===DONE=== | ||
--EXPECT-- | ||
===DONE=== |