From d521b3ce9dfc98d1e304a073a67b1fd7fd760235 Mon Sep 17 00:00:00 2001 From: Mikhail Galanin Date: Thu, 16 Mar 2023 16:03:21 +0000 Subject: [PATCH] Release memory in Imagick::getOptions() --- imagick_class.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/imagick_class.c b/imagick_class.c index bf71f9b9..22395b63 100644 --- a/imagick_class.c +++ b/imagick_class.c @@ -14428,7 +14428,9 @@ PHP_METHOD(Imagick, getOptions) option_value = MagickGetOption(intern->magick_wand, options[i]); IM_add_assoc_string(return_value, options[i], option_value); MagickRelinquishMemory(option_value); + DestroyString(options[i]); } + RelinquishMagickMemory(options); return; }