sonivox: prevent rejection of good but large MIDI files
A security patch that was trying to detect infinite loops
was accidentally rejecting very large MIDI files.
This is because there is a scanning pass that looks at the entire
file. That was generating a very high eventCount.
With this change, we do not check event counts during the scanning pass.
Test: Generate a MIDI files with more than 50000 events.
Test: There are some in b/112735915 and b/112575219
Test: mmma frameworks/av/cmds/stagefright
Test: adb push out/target/product/marlin/system/bin/stagefright /system/bin/.
Test: adb shell stagefright -a /sdcard/Download/verybigfile.mid
Test: It should play correctly and not abort.
(cherry picked from commit 123051dd0271ac0f245cb88c38878c6b21880632)
1 file changed