diff options
Diffstat (limited to 'apps/codecs/libmusepack')
-rw-r--r-- | apps/codecs/libmusepack/mpc_demux.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/codecs/libmusepack/mpc_demux.c b/apps/codecs/libmusepack/mpc_demux.c index e74e420b0d..70ac3bd416 100644 --- a/apps/codecs/libmusepack/mpc_demux.c +++ b/apps/codecs/libmusepack/mpc_demux.c | |||
@@ -128,7 +128,7 @@ mpc_demux_seek(mpc_demux * d, mpc_seek_t fpos, mpc_uint32_t min_bytes) { | |||
128 | mpc_int_t buf_fpos = next_pos - d->r->tell(d->r) + d->bytes_total; | 128 | mpc_int_t buf_fpos = next_pos - d->r->tell(d->r) + d->bytes_total; |
129 | 129 | ||
130 | // is desired byte position within lower and upper boundaries of buffer? | 130 | // is desired byte position within lower and upper boundaries of buffer? |
131 | if (buf_fpos >= 0 && buf_fpos + min_bytes <= DEMUX_BUFFER_SIZE) { | 131 | if (buf_fpos >= 0 && buf_fpos + min_bytes <= d->bytes_total) { |
132 | // desired bytes are available in current buffer | 132 | // desired bytes are available in current buffer |
133 | d->bits_reader.buff += buf_fpos - (d->bits_reader.buff - d->buffer); | 133 | d->bits_reader.buff += buf_fpos - (d->bits_reader.buff - d->buffer); |
134 | d->bits_reader.count = 8 - (fpos & 7); | 134 | d->bits_reader.count = 8 - (fpos & 7); |