Fix FS#11416. Resuming mpc was broken since r26032 due to false assumption of amount of buffered data.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26990 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
64d4ddf216
commit
dc8af759ce
1 changed files with 1 additions and 1 deletions
|
@ -128,7 +128,7 @@ mpc_demux_seek(mpc_demux * d, mpc_seek_t fpos, mpc_uint32_t min_bytes) {
|
|||
mpc_int_t buf_fpos = next_pos - d->r->tell(d->r) + d->bytes_total;
|
||||
|
||||
// is desired byte position within lower and upper boundaries of buffer?
|
||||
if (buf_fpos >= 0 && buf_fpos + min_bytes <= DEMUX_BUFFER_SIZE) {
|
||||
if (buf_fpos >= 0 && buf_fpos + min_bytes <= d->bytes_total) {
|
||||
// desired bytes are available in current buffer
|
||||
d->bits_reader.buff += buf_fpos - (d->bits_reader.buff - d->buffer);
|
||||
d->bits_reader.count = 8 - (fpos & 7);
|
||||
|
|
Loading…
Reference in a new issue