diff options
Diffstat (limited to 'apps/codecs/a52.c')
-rw-r--r-- | apps/codecs/a52.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/apps/codecs/a52.c b/apps/codecs/a52.c index 71e0fda432..0c69c6a2c7 100644 --- a/apps/codecs/a52.c +++ b/apps/codecs/a52.c | |||
@@ -161,7 +161,17 @@ next_track: | |||
161 | state = a52_init(0); | 161 | state = a52_init(0); |
162 | 162 | ||
163 | /* The main decoding loop */ | 163 | /* The main decoding loop */ |
164 | samplesdone = 0; | 164 | if (ci->id3->offset) { |
165 | if (ci->seek_buffer(ci->id3->offset)) { | ||
166 | samplesdone = (ci->id3->offset / ci->id3->bytesperframe) * | ||
167 | A52_SAMPLESPERFRAME; | ||
168 | ci->set_elapsed(samplesdone/(ci->id3->frequency / 1000)); | ||
169 | } | ||
170 | } | ||
171 | else { | ||
172 | samplesdone = 0; | ||
173 | } | ||
174 | |||
165 | while (1) { | 175 | while (1) { |
166 | if (ci->stop_codec || ci->new_track) | 176 | if (ci->stop_codec || ci->new_track) |
167 | break; | 177 | break; |