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 3961A4751E for ; Mon, 8 Jul 2024 22:24:56 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id EA25568DCB9; Tue, 9 Jul 2024 01:24:27 +0300 (EEST) Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5D5FD68DC1E for ; Tue, 9 Jul 2024 01:24:17 +0300 (EEST) Received: by mail.gandi.net (Postfix) with ESMTPSA id 9C0ACE0002 for ; Mon, 8 Jul 2024 22:24:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1720477456; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zC3qJbZs5POIlzA3pD1VcxDB49MUcOB2Y4SElJTSdSk=; b=B2gk8xOy+d3euHcRneD4k/Vo8TC3IbN3PmVI6fv/rTe84M3Zb16Y2G6wc8p35f2lw/GJXP DGXZejAYbYl9zj4HHwSSsacMXsa7KxHgkFaEOjQXq7qYHZkgyTepRhXx6SPVbbnggesKkc fGRJU7CQPnI6bkiN/SJHSe8tfpNBb3nNOMHc9+KlWUgpoZnTDBniGMVEPNglST3QZaxTF8 855YVu5MJCkxI0fZ5h9E+nckMp4+CypH6cyFQtJ4fs03bpCi7BcZz5jzBkW1ByGPMbqWji 0sBYTuXLYQhyFe5X8JtDlciG9rBYkzbkFahHJkJ6fPko4SwilnLrcFnMkcu9tw== From: Michael Niedermayer To: FFmpeg development discussions and patches Date: Tue, 9 Jul 2024 00:24:07 +0200 Message-ID: <20240708222410.773456-5-michael@niedermayer.cc> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240708222410.773456-1-michael@niedermayer.cc> References: <20240708222410.773456-1-michael@niedermayer.cc> MIME-Version: 1.0 X-GND-Sasl: michael@niedermayer.cc Subject: [FFmpeg-devel] [PATCH 5/8] avfilter/vf_premultiply: Use AV_PIX_MAX_PLANES 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 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: Helps: CID1435164 Out-of-bounds read Helps: CID1435165 Out-of-bounds read Helps: CID1435167 Out-of-bounds read Helps: CID1435169 Out-of-bounds read Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavfilter/vf_premultiply.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavfilter/vf_premultiply.c b/libavfilter/vf_premultiply.c index e077d46a9a0..5e97c2000f2 100644 --- a/libavfilter/vf_premultiply.c +++ b/libavfilter/vf_premultiply.c @@ -36,8 +36,8 @@ typedef struct ThreadData { typedef struct PreMultiplyContext { const AVClass *class; - int width[4], height[4]; - int linesize[4]; + int width[AV_VIDEO_MAX_PLANES], height[AV_VIDEO_MAX_PLANES]; + int linesize[AV_VIDEO_MAX_PLANES]; int nb_planes; int planes; int inverse; @@ -45,7 +45,7 @@ typedef struct PreMultiplyContext { int half, depth, offset, max; FFFrameSync fs; - void (*premultiply[4])(const uint8_t *msrc, const uint8_t *asrc, + void (*premultiply[AV_VIDEO_MAX_PLANES])(const uint8_t *msrc, const uint8_t *asrc, uint8_t *dst, ptrdiff_t mlinesize, ptrdiff_t alinesize, ptrdiff_t dlinesize, -- 2.45.2 _______________________________________________ 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".