More robust implementation of MPEG frame header search. The parser will not only...
commitce573d4b8335a8d91edb7fed7defbaf225f381cd
authorBuschel <Buschel@a1c6a512-1295-4272-9138-f99709370657>
Wed, 16 Mar 2011 18:45:03 +0000 (16 18:45 +0000)
committerBuschel <Buschel@a1c6a512-1295-4272-9138-f99709370657>
Wed, 16 Mar 2011 18:45:03 +0000 (16 18:45 +0000)
tree63a893259b1183177e7166acd65b6e9926690fb4
parent8f34278110d7b73f40d9dd35207fa937581e4d55
More robust implementation of MPEG frame header search. The parser will not only search for the very first byte sequence that looks like a valid MPEG frame header. It will search for a valid MPEG frame header sequence, decode it, and probe if there is a consecutive MPEG frame header of the same type (MPEG version, layer, sampling frequency) at the expected position. This approach will reduce false detection of MPEG frame headers in case of errorous metadata or garbaged files. Fixes FS#12007.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29603 a1c6a512-1295-4272-9138-f99709370657
apps/mp3data.c
apps/mp3data.h
apps/plugin.h