From: Marton Balint Date: Thu, 11 Feb 2021 22:03:26 +0000 (+0100) Subject: avdevice/pulse_audio_dec: only set adjust latency flag if fragment_size is not set X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=7f059a250bb7bcbf7bba537c1a059a5934413035;p=ffmpeg avdevice/pulse_audio_dec: only set adjust latency flag if fragment_size is not set Otherwise fragment_size is ignored. Signed-off-by: Marton Balint --- diff --git a/libavdevice/pulse_audio_dec.c b/libavdevice/pulse_audio_dec.c index 6dea332bebe..0454a643dda 100644 --- a/libavdevice/pulse_audio_dec.c +++ b/libavdevice/pulse_audio_dec.c @@ -218,7 +218,7 @@ static av_cold int pulse_read_header(AVFormatContext *s) ret = pa_stream_connect_record(pd->stream, device, &attr, PA_STREAM_INTERPOLATE_TIMING - |PA_STREAM_ADJUST_LATENCY + | (pd->fragment_size == -1 ? PA_STREAM_ADJUST_LATENCY : 0) |PA_STREAM_AUTO_TIMING_UPDATE); if (ret < 0) {