mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-18 17:11:53 +00:00
Fix gapless playback
This commit is contained in:
parent
8d74d48809
commit
67ae0fcf8d
1 changed files with 2 additions and 3 deletions
|
@ -1104,6 +1104,8 @@ impl Future for PlayerInternal {
|
||||||
match decoder.next_packet() {
|
match decoder.next_packet() {
|
||||||
Ok(result) => {
|
Ok(result) => {
|
||||||
if let Some((new_stream_position_ms, ref packet)) = result {
|
if let Some((new_stream_position_ms, ref packet)) = result {
|
||||||
|
*stream_position_ms = new_stream_position_ms;
|
||||||
|
|
||||||
if !passthrough {
|
if !passthrough {
|
||||||
match packet.samples() {
|
match packet.samples() {
|
||||||
Ok(_) => {
|
Ok(_) => {
|
||||||
|
@ -1144,9 +1146,6 @@ impl Future for PlayerInternal {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
// position, even if irrelevant, must be set so that seek() is called
|
|
||||||
*stream_position_ms = new_stream_position_ms;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue