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 ESMTPS id 4EF9A4C2DE for ; Thu, 6 Feb 2025 15:01:36 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 7AEED68BCD6; Thu, 6 Feb 2025 17:01:32 +0200 (EET) Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 835A168B518 for ; Thu, 6 Feb 2025 17:01:26 +0200 (EET) Received: by mail.gandi.net (Postfix) with ESMTPSA id E3B6B44368 for ; Thu, 6 Feb 2025 15:01:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1738854086; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kxG7sKvJpD9Fk+5maaKpVtodsLhHalKXIpWvJ+5efrY=; b=f37Vd/VwM8ioKtWJailzOTc2A4iUjoFH0kJQYPpJiFvEi2+NDKijaqnIViHtQ0hNGxVCgh XBoT5nIHSF8Dc9uMeV6hiL4c0rewmfDraUsX3yPc/67m3c/Npo+cehA8FQBMKHPmxST1RX 0WJxv4cc1HzkZNG60gb0elm47WipC921nd6i5Q9PAbU+CTZy+mbmUwCpL888BVyJ1UOWU5 CbQwhP8N0s/JbiHM51idbCB6vPu5MSl9NN5SPbur7mlfvKMttXQlumMLzjGlSIjt181wCA NBwm4WhalgF3NeffWvdxSxCUQwKH+3OqDbsYgLJm90kheyAQQCyW5lwqq5u17A== Date: Thu, 6 Feb 2025 16:01:24 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20250206150124.GO4991@pb2> References: <1f41aeb9976efbcd2930a039418d27f7307ed757.camel@haerdin.se> MIME-Version: 1.0 In-Reply-To: <1f41aeb9976efbcd2930a039418d27f7307ed757.camel@haerdin.se> X-GND-State: clean X-GND-Score: -85 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgddvieeilecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucesvcftvggtihhpihgvnhhtshculddquddttddmnegfrhhlucfvnfffucdludehmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofhitghhrggvlhcupfhivgguvghrmhgrhigvrhcuoehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgeqnecuggftrfgrthhtvghrnhepudetvdfhudeuudegudefgfehhfevvdfggfffkefhvdfgvdetffdtjeekheetfeehnecukfhppeeguddrieeirdeijedruddufeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeeguddrieeirdeijedruddufedphhgvlhhopehlohgtrghlhhhoshhtpdhmrghilhhfrhhomhepmhhitghhrggvlhesnhhivgguvghrmhgrhigvrhdrtggtpdhnsggprhgtphhtthhopedupdhrtghpthhtohepfhhfmhhpvghgqdguvghvvghlsehffhhmphgvghdrohhrgh X-GND-Sasl: michael@niedermayer.cc Subject: Re: [FFmpeg-devel] [PATCH 4/8] avformat/flacdec: Return correct error-codes on read-failure 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: multipart/mixed; boundary="===============3005802580306119830==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============3005802580306119830== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="W6SrFVivMudS4zlG" Content-Disposition: inline --W6SrFVivMudS4zlG Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Feb 05, 2025 at 03:20:30PM +0100, Tomas H=E4rdin wrote: >=20 > flacdec.c | 16 ++++++++++++---- > 1 file changed, 12 insertions(+), 4 deletions(-) > da53ae8bb59c5ee934cc7ba809955e0446168675 0004-avformat-flacdec-Return-co= rrect-error-codes-on-read-.patch > From c81e350d5419cf02f029ce006d94f257bc18fb97 Mon Sep 17 00:00:00 2001 > From: Ulrik > Date: Thu, 26 Jan 2023 17:51:02 +0100 > Subject: [PATCH 4/8] avformat/flacdec: Return correct error-codes on > read-failure >=20 > Forward errors from `avio_read` directly. When `avio_read` sees EOF before > expected bytes can be read, consistently return `AVERROR_INVALIDDATA` >=20 > We used to return `AVERROR(AVERROR_INVALIDDATA)` when failing to read > metadata block headers. `AVERROR_INVALIDDATA` is already negative, so > wrapping in `AVERROR` leads to double-negation. >=20 > We used to return `AVERROR(EIO)` when failing to read extended metadata. > However, many times, the IO-layer is not at fault, the input data is simp= ly > corrupted (truncated), so we return `AVERROR_INVALIDDATA` here as well. >=20 > --- >=20 > Tomas: changed to use AVERROR_EOF > --- > libavformat/flacdec.c | 16 ++++++++++++---- > 1 file changed, 12 insertions(+), 4 deletions(-) should be fine / LGTM thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB When the tyrant has disposed of foreign enemies by conquest or treaty, and there is nothing more to fear from them, then he is always stirring up some war or other, in order that the people may require a leader. -- Plato --W6SrFVivMudS4zlG Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEKAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCZ6TOxAAKCRBhHseHBAsP q8ukAKCamAw4kdnzJ3iZiiMTr2vKNBpC1gCgjXYExPbeIDJMAdWjS2XFBBCS1bk= =pRFM -----END PGP SIGNATURE----- --W6SrFVivMudS4zlG-- --===============3005802580306119830== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ 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". --===============3005802580306119830==--