From patchwork Sun Feb 21 16:46:55 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marton Balint X-Patchwork-Id: 25857 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 2F11844A12B for ; Sun, 21 Feb 2021 18:47:41 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 02E7E68A181; Sun, 21 Feb 2021 18:47:41 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from iq.passwd.hu (iq.passwd.hu [217.27.212.140]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 364FE689D06 for ; Sun, 21 Feb 2021 18:47:35 +0200 (EET) Received: from localhost (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id C77F1E502C; Sun, 21 Feb 2021 17:47:34 +0100 (CET) X-Virus-Scanned: amavisd-new at passwd.hu Received: from iq.passwd.hu ([127.0.0.1]) by localhost (iq.passwd.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ggyp-kDqBsUu; Sun, 21 Feb 2021 17:47:04 +0100 (CET) Received: from bluegene.passwd.hu (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id CF05CE4F9F; Sun, 21 Feb 2021 17:47:03 +0100 (CET) From: Marton Balint To: ffmpeg-devel@ffmpeg.org Date: Sun, 21 Feb 2021 17:46:55 +0100 Message-Id: <20210221164659.19180-1-cus@passwd.hu> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/5] avdevice/alsa_dec: do not set codecpar frame_size X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Marton Balint Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Constant frame size is not guaranteed if the read call interrupted by a signal, or if non-blocking mode is used. Signed-off-by: Marton Balint --- libavdevice/alsa_dec.c | 1 - 1 file changed, 1 deletion(-) diff --git a/libavdevice/alsa_dec.c b/libavdevice/alsa_dec.c index 36494e921c..6d568737b3 100644 --- a/libavdevice/alsa_dec.c +++ b/libavdevice/alsa_dec.c @@ -83,7 +83,6 @@ static av_cold int audio_read_header(AVFormatContext *s1) st->codecpar->codec_id = codec_id; st->codecpar->sample_rate = s->sample_rate; st->codecpar->channels = s->channels; - st->codecpar->frame_size = s->frame_size; avpriv_set_pts_info(st, 64, 1, 1000000); /* 64 bits pts in us */ /* microseconds instead of seconds, MHz instead of Hz */ s->timefilter = ff_timefilter_new(1000000.0 / s->sample_rate,