summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-10-14 22:07:04 +0200
committerwm4 <wm4@nowhere>2014-10-14 22:07:04 +0200
commit312531c08c2376257a43bd40e4ace08c2893da4d (patch)
tree6e1144ecc1cecb65aaa7b829688043540503efb7
parentfe5ba6e21797bb4154cc42a6584cc2532658ec4b (diff)
downloadmpv-312531c08c2376257a43bd40e4ace08c2893da4d.tar.bz2
mpv-312531c08c2376257a43bd40e4ace08c2893da4d.tar.xz
audio/out/push: reset projected EOF time on new data
Seems like this could theoretically happen in low buffer situations, but I haven't spotted this behavior in the wild.
-rw-r--r--audio/out/push.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/audio/out/push.c b/audio/out/push.c
index f94d445852..20337ef9d2 100644
--- a/audio/out/push.c
+++ b/audio/out/push.c
@@ -234,7 +234,10 @@ static int play(struct ao *ao, void **data, int samples, int flags)
p->final_chunk = is_final;
p->paused = false;
- p->still_playing |= write_samples > 0;
+ if (got_data) {
+ p->still_playing = true;
+ p->expected_end_time = 0;
+ }
// If we don't have new data, the decoder thread basically promises it
// will send new data as soon as it's available.