[FFmpeg-devel] [PATCH] Remove noise message from MP3 decoder

Michael Niedermayer michaelni at gmx.at
Thu Sep 8 21:09:04 CEST 2011


On Wed, Sep 07, 2011 at 01:34:44AM +0100, Chris Rankin wrote:
> Hi,
>
> I was testing xine recently with an old movie trailer when I noticed that 
> my console log was getting spammed with these messages:
>
> [mp3 @ 0xad218660] incorrect frame size
> [mp3 @ 0xad218660] incorrect frame size
> [mp3 @ 0xad218660] incorrect frame size
> [mp3 @ 0xad218660] incorrect frame size
> [mp3 @ 0xad218660] incorrect frame size
> [mp3 @ 0xad218660] incorrect frame size
>
> Digging further, I discovered that the MP3 decoder in libavcodec will 
> always print this message whenever it is handed a packet with more than 
> one frame in. There are a number of problems with this:
>
> a) This isn't an error. The audio stream plays fine.
> b) AV_LOG_ERROR is supposed to be reserved for "Something went wrong and 
> cannot losslessly be recovered". However, the situation *is* "recovered" 
> from without loss.
> c) avcodec_decode_audio3() is documented as accepting an AVPacket. But if 
> an AVPacket can legitimately contain multiple frames then why is the MP3 
> decoder complaining about it in the first place?
>
> I've attached two alternative patches for this: one (my preferred 
> solution) just removes the error message entirely. The second demotes the 
> message to DEBUG level instead, just in case someone might actually want 
> to see it. (I can't imagine why, though.)

I ve applied the 2nd one.
The reason why some like nicolas where concerend is i belive because
if a demuxer returns such multi packets then stream copying
(-acodec copy) generates invalid files.
As this is happening with a video player only, its a non issue here.

Thanks for the patch!

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

No snowflake in an avalanche ever feels responsible. -- Voltaire
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110908/c6ad388a/attachment.asc>


More information about the ffmpeg-devel mailing list