From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.ffmpeg.org (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id BB9BC4F21D for ; Mon, 16 Jun 2025 22:44:14 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTP id B68F768C916; Tue, 17 Jun 2025 01:44:12 +0300 (EEST) Received: from iq.passwd.hu (iq.passwd.hu [217.27.212.140]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTP id D988B68C8BB for ; Tue, 17 Jun 2025 01:44:09 +0300 (EEST) Received: from localhost (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id C0304ED967; Tue, 17 Jun 2025 00:41:15 +0200 (CEST) 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 L2KHH9SfY1x1; Tue, 17 Jun 2025 00:41:14 +0200 (CEST) Received: from bluegene.passwd.hu (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id 5F62CED95E; Tue, 17 Jun 2025 00:41:14 +0200 (CEST) From: Marton Balint To: ffmpeg-devel@ffmpeg.org Date: Tue, 17 Jun 2025 00:43:51 +0200 Message-ID: <20250616224404.16142-1-cus@passwd.hu> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/7] fftools/ffmpeg_filter: simplify control flow in read_frames X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 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 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: No functional change. Signed-off-by: Marton Balint --- fftools/ffmpeg_filter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fftools/ffmpeg_filter.c b/fftools/ffmpeg_filter.c index e0c40ffe00..a0dc4c745e 100644 --- a/fftools/ffmpeg_filter.c +++ b/fftools/ffmpeg_filter.c @@ -2672,7 +2672,7 @@ static int read_frames(FilterGraph *fg, FilterGraphThread *fgt, ret = avfilter_graph_request_oldest(fgt->graph); if (ret == AVERROR(EAGAIN)) { fgt->next_in = choose_input(fg, fgt); - break; + return 0; } else if (ret < 0) { if (ret == AVERROR_EOF) av_log(fg, AV_LOG_VERBOSE, "Filtergraph returned EOF, finishing\n"); @@ -2702,7 +2702,7 @@ static int read_frames(FilterGraph *fg, FilterGraphThread *fgt, did_step = 1; } - return (fgp->nb_outputs_done == fg->nb_outputs) ? AVERROR_EOF : 0; + return AVERROR_EOF; } static void sub2video_heartbeat(InputFilter *ifilter, int64_t pts, AVRational tb) -- 2.43.0 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".