On Fri, Jul 13, 2018 at 12:35:07PM +0200, Karsten Otto wrote: > MP3 frames may not be aligned to aa chunk boundaries. When seeking, > calculate the expected frame offset in the target chunk. Adjust the > timestamp and truncate the next packet accordingly. > > This solution works for the majority of tested audio material. For > some rare encodings with mp3 padding or embedded id3 tags, it will > mispredict the correct offset, and at worst skip an extra frame. > ---
> This revision includes some comments documenting how/why it works. this is not what i meant. The input can be arbitrary, and generally would be manually created to exploit the code. iam not at all against documenting what it "// normally," does but the question is what makes a check unneeded I was more thinking of a single comment in place of the missing check explaining why it is _guranteed_ to be unneeded. It could also be done in form of a documented av_assert0(); Also if you need a lot of text to explain this, theres a problem. People who work on this in the future must understand what condition they need to maintain to make this stay true. thanks [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Does the universe only have a finite lifespan? No, its going to go on forever, its just that you wont like living in it. -- Hiranya Peiri
signature.asc
Description: PGP signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel