Quick fix to allow certain MP3 files to play. If a Xing or Info header didn't properly set both the frame count and byte count, then the bitrate was set to zero, preventing playback. Better to use the bitrate of the first audio frame in this case. (More sanity checking of the frame count should perhaps be done.)

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22611 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Magnus Holmgren 2009-09-03 21:14:13 +00:00
parent af2dcbb8e1
commit 7f03af08fa

View file

@ -449,8 +449,6 @@ int get_mp3file_info(int fd, struct mp3info *info)
else
info->bitrate = info->byte_count / (info->file_time >> 3);
}
else
info->bitrate = 0;
if (vbrheader[7] & VBR_TOC_FLAG) /* Is table-of-contents there? */
{