From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.ffmpeg.org (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id C13ED4CBED for ; Sun, 13 Jul 2025 01:10:53 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTP id 7A4DE68F554; Sun, 13 Jul 2025 04:10:40 +0300 (EEST) Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTPS id C0E3168F43E for ; Sun, 13 Jul 2025 04:10:32 +0300 (EEST) Received: by mail.gandi.net (Postfix) with ESMTPSA id 116A243A01 for ; Sun, 13 Jul 2025 01:10:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1752369032; 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=vLHn8+R7CxHffPTkeCvS+5iCCLQdolykIAobbVoQFC0=; b=e2qR/w0Q/46b62RIkemsJqKEzzyCBrUMfaddfvx7Zs+qoae4N0QjNCSDRLWmMSw2ETKzlQ zSN9L/qCjP7FE5RWs16buiJTgDbqkkwP/1RCBh7NgXUZf7pSCCIAZiwrXHzzeVb3hOwimB TMChYage6v5+cjFFX8FSZehVV8aqO+OD8D3kB7MnIVLISm7nWqNVfnCnJ7cboa3uS3SI75 SRBm1eTqTj5LbyDl8wbpm1DbG/GB9PqjPLZLUDieM2/IXr2RIU5AYAVLxbdZREUoCOrdQa a7OoFqWFYgwa0zsm31Vebpg5rycRevx0GCdg09tntsDXaCtFtkZKnXVzwzOhGw== From: Michael Niedermayer To: FFmpeg development discussions and patches Date: Sun, 13 Jul 2025 03:10:27 +0200 Message-ID: <20250713011030.1156550-2-michael@niedermayer.cc> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250713011030.1156550-1-michael@niedermayer.cc> References: <20250713011030.1156550-1-michael@niedermayer.cc> MIME-Version: 1.0 X-GND-State: clean X-GND-Score: -85 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdefgdegjeejvdcutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucesvcftvggtihhpihgvnhhtshculddquddttddmnegfrhhlucfvnfffucdludehmdenucfjughrpefhvffufffkofgjfhgggfestdekredtredttdenucfhrhhomhepofhitghhrggvlhcupfhivgguvghrmhgrhigvrhcuoehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgeqnecuggftrfgrthhtvghrnhepgeejhfetgefhgfeludegvdduvdffgeefvddtheetlefhueeitdevffevfeehhefgnecuffhomhgrihhnpehgihhthhhusgdrtghomhenucfkphepgedurdeiiedrieehrddujeeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepgedurdeiiedrieehrddujeeipdhhvghloheplhhotggrlhhhohhsthdpmhgrihhlfhhrohhmpehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgdpnhgspghrtghpthhtohepuddprhgtphhtthhopehffhhmphgvghdquggvvhgvlhesfhhfmhhpvghgrdhorhhg X-GND-Sasl: michael@niedermayer.cc Subject: [FFmpeg-devel] [PATCH 2/5] avformat/concatdec: Clip duration in one more case in get_best_effort_duration() 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: Fixes: signed integer overflow: 40000 - -9223372036854770000 cannot be represented in type 'long' Fixes: 427262541/clusterfuzz-testcase-minimized-ffmpeg_dem_CONCAT_fuzzer-4831506940100608 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavformat/concatdec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c index fe65d0c7688..e0c2c872482 100644 --- a/libavformat/concatdec.c +++ b/libavformat/concatdec.c @@ -326,7 +326,7 @@ static int64_t get_best_effort_duration(ConcatFile *file, AVFormatContext *avf) if (file->outpoint != AV_NOPTS_VALUE) return av_sat_sub64(file->outpoint, file->file_inpoint); if (avf->duration > 0) - return avf->duration - (file->file_inpoint - file->file_start_time); + return av_sat_sub64(avf->duration, file->file_inpoint - file->file_start_time); if (file->next_dts != AV_NOPTS_VALUE) return file->next_dts - file->file_inpoint; return AV_NOPTS_VALUE; -- 2.49.0 _______________________________________________ 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".