From bc1370041ddfea92c435db148ecf4e91bc85000b Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 27 Nov 2014 18:52:22 +0100 Subject: audio: alternative fix for previous commit This is a somewhat obscure situation, and happens only if audio starts again after it has ended (in particular can happens with files where audio starts later). It doesn't matter much whether audio starts immediately or some milliseconds later, so simplify it. --- player/audio.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'player') diff --git a/player/audio.c b/player/audio.c index a1e1182e8a..dc1d305525 100644 --- a/player/audio.c +++ b/player/audio.c @@ -514,10 +514,7 @@ static void do_fill_audio_out_buffers(struct MPContext *mpctx, double endpts) // restart audio properly. This helps with video files where audio starts // later. Retrying is needed to get the correct sync PTS. if (mpctx->audio_status >= STATUS_DRAINING && status == AD_OK) { - if (!mpctx->paused) { - mpctx->audio_status = STATUS_SYNCING; - mpctx->sleeptime = 0; - } + mpctx->audio_status = STATUS_SYNCING; return; // retry on next iteration } -- cgit v1.2.3