From 0e564798d4c8291f9a5e2b1c01c1a0177a8c5fb0 Mon Sep 17 00:00:00 2001 From: Rudolph Gottesheim Date: Thu, 11 Jul 2024 13:22:28 +0200 Subject: [PATCH] Use more precise return types for getimagesize and getimagesizefromstring - Key 0 (the image width) is always positive - Key 1 (the image height) is always positive - Key 2 is always one of the `IMAGETYPE_*` constants --- dictionaries/CallMap.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dictionaries/CallMap.php b/dictionaries/CallMap.php index 03564be9a30..903a3698d2a 100644 --- a/dictionaries/CallMap.php +++ b/dictionaries/CallMap.php @@ -3304,8 +3304,8 @@ 'gethostbyname' => ['string', 'hostname'=>'string'], 'gethostbynamel' => ['list|false', 'hostname'=>'string'], 'gethostname' => ['string|false'], -'getimagesize' => ['array{0:int, 1: int, 2: int, 3: string, mime: string, channels?: 3|4, bits?: int}|false', 'filename'=>'string', '&w_image_info='=>'array'], -'getimagesizefromstring' => ['array{0:int, 1: int, 2: int, 3: string, mime: string, channels?: 3|4, bits?: int}|false', 'string'=>'string', '&w_image_info='=>'array'], +'getimagesize' => ['array{0: positive-int, 1: positive-int, 2: IMAGETYPE_*, 3: string, mime: string, channels?: 3|4, bits?: int}|false', 'filename'=>'string', '&w_image_info='=>'array'], +'getimagesizefromstring' => ['array{0: positive-int, 1: positive-int, 2: IMAGETYPE_*, 3: string, mime: string, channels?: 3|4, bits?: int}|false', 'string'=>'string', '&w_image_info='=>'array'], 'getlastmod' => ['int|false'], 'getmxrr' => ['bool', 'hostname'=>'string', '&w_hosts'=>'array', '&w_weights='=>'array'], 'getmygid' => ['int|false'],