summaryrefslogtreecommitdiffstats
path: root/player/audio.c
diff options
context:
space:
mode:
Diffstat (limited to 'player/audio.c')
-rw-r--r--player/audio.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/player/audio.c b/player/audio.c
index 12f9d03cb4..067bbece7d 100644
--- a/player/audio.c
+++ b/player/audio.c
@@ -689,7 +689,8 @@ void fill_audio_out_buffers(struct MPContext *mpctx, double endpts)
assert(played >= 0 && played <= data.samples);
mp_audio_buffer_skip(mpctx->ao_buffer, played);
- mpctx->audio_drop_throttle -= played / play_samplerate;
+ mpctx->audio_drop_throttle =
+ MPMAX(0, mpctx->audio_drop_throttle - played / play_samplerate);
dump_audio_stats(mpctx);