From aaafbfcc06a8e69bca78641af70f43b2ad12e56a Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 19 Jan 2016 22:47:18 +0100 Subject: audio: remove initial decoding retry limitation Seems useless. This only helped in one case: one audio stream in the sample av_find_best_stream_fails.ts had a AC3 packets which couldn't be decoded, and for which avcodec_decode_audio4() returned 0 forever. In this specific case, playback will now not start, and you have to deselect audio manually. (If someone complains, the old behavior might be restored, but differently.) Also remove the stale "bitrate" field. --- player/audio.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'player/audio.c') diff --git a/player/audio.c b/player/audio.c index d4b4d97f49..5a62a69d1a 100644 --- a/player/audio.c +++ b/player/audio.c @@ -531,14 +531,6 @@ void fill_audio_out_buffers(struct MPContext *mpctx, double endpts) int r = initial_audio_decode(mpctx->d_audio); if (r == AD_WAIT) return; // continue later when new data is available - if (r != AD_OK) { - mpctx->d_audio->init_retries += 1; - if (mpctx->d_audio->init_retries >= 50) { - MP_ERR(mpctx, "Error initializing audio.\n"); - error_on_track(mpctx, mpctx->current_track[0][STREAM_AUDIO]); - return; - } - } reinit_audio_chain(mpctx); mpctx->sleeptime = 0; return; // try again next iteration -- cgit v1.2.3