diff options
author | waker <wakeroid@gmail.com> | 2009-08-13 19:23:51 +0200 |
---|---|---|
committer | waker <wakeroid@gmail.com> | 2009-08-13 19:24:04 +0200 |
commit | ccaf593e039b0a19aa3cf4601ae283fe438224cd (patch) | |
tree | 34c33fa46ee04ed92b07408a6ede71fd6ed44d7b | |
parent | 78ecc1091f2023c194848ad15664cf4f7705a9bd (diff) |
fixed initial mp3 duration calc
-rw-r--r-- | cmp3.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -276,7 +276,7 @@ cmp3_scan_stream (buffer_t *buffer, float position) { } } else { - packetlength = 0; + continue; } buffer->version = ver; buffer->layer = layer; @@ -1345,6 +1345,7 @@ cmp3_insert (playItem_t *after, const char *fname) { } fseek (fp, 0, SEEK_END); int sz = ftell (fp); + assert (buffer.packetlength); int nframes = sz / buffer.packetlength; it->duration = nframes * buffer.frameduration; |