From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 1D30247D25 for ; Sat, 17 Feb 2024 17:09:59 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4729168D2D0; Sat, 17 Feb 2024 19:09:56 +0200 (EET) Received: from relay3-d.mail.gandi.net (relay3-d.mail.gandi.net [217.70.183.195]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id BEBF168D1E5 for ; Sat, 17 Feb 2024 19:09:49 +0200 (EET) Received: by mail.gandi.net (Postfix) with ESMTPSA id 52EFC60004 for ; Sat, 17 Feb 2024 17:09:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1708189788; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc; bh=tL5oExu0Iw5Bn45M/ryRem0reLw76IgGxPfgUkckCrQ=; b=OoLZ6xGXqyWQYTKsCPcl9ItWQmcOoe0NVDS0HBWFRxEpqf6zRjYI82NlB+U/X1CA8s379u k4UXppECVdyi4pUIQOo78AgIu4VMq6yxRC6CvreXfX5GuduVaP47t/A9Uiell4ZuUXI52l QhJwyxqINzPxwGOrnFC0P1Tp579qq99JA72nKwt807KuEgrXh3Rig0gnYFqIXKWdlF30nT ZvFM09T0OJYE8Hr/7YTRNMuVP8WJsPmX8kPkMeP8BtLipJkOlunkbiqyU6eX1UE+GJIQm3 HHyDta2LZmgktWTdZyxcDHQ+/3br3+92oG8IIDSNW2/+KS+0DmWyccY2/RkOAQ== From: Michael Niedermayer To: FFmpeg development discussions and patches Date: Sat, 17 Feb 2024 18:09:46 +0100 Message-Id: <20240217170947.25351-1-michael@niedermayer.cc> X-Mailer: git-send-email 2.17.1 X-GND-Sasl: michael@niedermayer.cc Subject: [FFmpeg-devel] [PATCH 1/2] swscale/utils: Allocate more dithererror X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Fixes: out of array read Signed-off-by: Michael Niedermayer --- libswscale/utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libswscale/utils.c b/libswscale/utils.c index ec822ff5d92..4dc0fbfefbf 100644 --- a/libswscale/utils.c +++ b/libswscale/utils.c @@ -1885,7 +1885,7 @@ static av_cold int sws_init_single_context(SwsContext *c, SwsFilter *srcFilter, } for (i = 0; i < 4; i++) - if (!FF_ALLOCZ_TYPED_ARRAY(c->dither_error[i], c->dstW + 2)) + if (!FF_ALLOCZ_TYPED_ARRAY(c->dither_error[i], c->dstW + 3)) goto nomem; c->needAlpha = (CONFIG_SWSCALE_ALPHA && isALPHA(c->srcFormat) && isALPHA(c->dstFormat)) ? 1 : 0; -- 2.17.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".