From: Christoph M. Becker Date: Sun, 11 Aug 2019 14:40:40 +0000 (+0200) Subject: Fix arginfo X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0c5b75b0635138b43237d650cdf5e72a60cef76f;p=php Fix arginfo The second parameter of `imagexbm()` is nullable. --- diff --git a/ext/gd/gd.stub.php b/ext/gd/gd.stub.php index fe7f7aa5f0..75d0916751 100644 --- a/ext/gd/gd.stub.php +++ b/ext/gd/gd.stub.php @@ -117,7 +117,7 @@ function imagecreatefrombmp(string $filename) {} function imagecreatefromtga(string $filename) {} #endif -function imagexbm($im, string $filename, int $foreground = UNKNOWN): bool {} +function imagexbm($im, ?string $filename, int $foreground = UNKNOWN): bool {} function imagegif($im, $to = NULL): bool {} diff --git a/ext/gd/gd_arginfo.h b/ext/gd/gd_arginfo.h index ac3b68a2f0..0544802c7e 100644 --- a/ext/gd/gd_arginfo.h +++ b/ext/gd/gd_arginfo.h @@ -196,7 +196,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_imagexbm, 0, 2, _IS_BOOL, 0) ZEND_ARG_INFO(0, im) - ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0) + ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 1) ZEND_ARG_TYPE_INFO(0, foreground, IS_LONG, 0) ZEND_END_ARG_INFO()