From patchwork Thu Jun 16 19:55:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Khirnov X-Patchwork-Id: 36289 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:1a22:b0:84:42e0:ad30 with SMTP id cj34csp1130234pzb; Thu, 16 Jun 2022 13:09:45 -0700 (PDT) X-Google-Smtp-Source: AGRyM1shY2NPGAeoLrJyNf2kXmIEbkm1wm1VcYGDbyKJcxw6qn07lhhae8NBNOny8o7pYRkH8htx X-Received: by 2002:a05:6402:5250:b0:42e:726e:e064 with SMTP id t16-20020a056402525000b0042e726ee064mr8544006edd.153.1655410185615; Thu, 16 Jun 2022 13:09:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655410185; cv=none; d=google.com; s=arc-20160816; b=DjI7tB3PR6YVUHjbK+lfGxg1gg0bPnJhy1ogIl5CmLdPkHjIiv2qtiXrHuz+ugYQDB WSfTm5xkqdXguBqhsVykSrQxU+NPmRNdaZz8/n6XLT5B/UGD02JTxGlikS6hp0fK7j4U 6nB7Rh2CRhPMAA21SNub/p6HmYw1f+b4LGLnUUXe1lsZsYeEs+cLK4cvWXGML7Wjaqgc JkdCEYImuEQLYFRUJqNdmHXPag+IaodFgZxs1T+PTNiIJhC+ssKxBD0lE0N6SkhcvZVR j36Cz7wQOQV/RAPex1JS2Wzwtxzf2bfFRv0V4YT5gd1SRNdnbpsgkf1ECwKV80knAFnN Dcsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:reply-to:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:subject:mime-version:references:in-reply-to:message-id :date:to:from:delivered-to; bh=LT4u2dY0w2e+Xkc78y4S5hnoD/ln6g7G3P5DmF+I/8U=; b=f0l5VIHQVmRaWNRMSmErOnC2e0jTUb65QtEQF0F5FYZBR6HG50ovw3Ev5Xbx4D/X4o L//rRi0NZ/g+tKVNv6MJBazSG/HozK9Lqf1HAArH1uiYkqnKetFx56wWidSPE58ZzNv6 ibzDL/WtXNolzx+vOqpssCSFffrPOCC+IonXCpiJjI7q9ydzBKnoGrIxzTJhSlGcec+n 1ZD2C8gouvcyPTf+w2cclO7zk9JB0/WrUyaTWXDCX76YyJIN9CQnLgpkb4IMWBo4jDrG Gfpeoai/i6HfIYmapT6Ls8O/kjTp+NB6IcXwSXKWStWEAVux+3VuKV3pLqcALYov0zsE flNQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id bo23-20020a0564020b3700b0042e2569656csi2824519edb.160.2022.06.16.13.09.45; Thu, 16 Jun 2022 13:09:45 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 8836668B8C6; Thu, 16 Jun 2022 23:09:42 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail0.khirnov.net (red.khirnov.net [176.97.15.12]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 43BAB68B834 for ; Thu, 16 Jun 2022 23:09:36 +0300 (EEST) Received: from localhost (localhost [IPv6:::1]) by mail0.khirnov.net (Postfix) with ESMTP id E6D6724017E for ; Thu, 16 Jun 2022 22:09:35 +0200 (CEST) Received: from mail0.khirnov.net ([IPv6:::1]) by localhost (mail0.khirnov.net [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id sG3F3xTpWvC5 for ; Thu, 16 Jun 2022 22:09:35 +0200 (CEST) Received: from libav.khirnov.net (libav.khirnov.net [IPv6:2a00:c500:561:201::7]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "libav.khirnov.net", Issuer "smtp.khirnov.net SMTP CA" (verified OK)) by mail0.khirnov.net (Postfix) with ESMTPS id 7BA31240175 for ; Thu, 16 Jun 2022 22:09:35 +0200 (CEST) Received: by libav.khirnov.net (Postfix, from userid 1000) id 1050E3A21D9; Thu, 16 Jun 2022 22:03:31 +0200 (CEST) From: Anton Khirnov To: ffmpeg-devel@ffmpeg.org Date: Thu, 16 Jun 2022 21:55:30 +0200 Message-Id: <20220616195534.5278-31-anton@khirnov.net> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220616195534.5278-1-anton@khirnov.net> References: <20220616195534.5278-1-anton@khirnov.net> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 31/35] fftools/ffmpeg_mux: do not call exit_program() in print_sdp() 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 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: BxkbQIZKdoHw Return an error instead, as is already done in other places in this function. --- fftools/ffmpeg_mux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fftools/ffmpeg_mux.c b/fftools/ffmpeg_mux.c index cf24ae7700..2abadd3f9b 100644 --- a/fftools/ffmpeg_mux.c +++ b/fftools/ffmpeg_mux.c @@ -270,7 +270,7 @@ static int print_sdp(void) avc = av_malloc_array(nb_output_files, sizeof(*avc)); if (!avc) - exit_program(1); + return AVERROR(ENOMEM); for (i = 0, j = 0; i < nb_output_files; i++) { if (!strcmp(output_files[i]->format->name, "rtp")) { avc[j] = output_files[i]->mux->fc;