Message ID | 20200913025753.274772-5-andreas.rheinhardt@gmail.com |
---|---|
State | Accepted |
Commit | 8bbd97109c993b50a00a88f2b773252ed1b83fc0 |
Headers | show
Return-Path: <ffmpeg-devel-bounces@ffmpeg.org> 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 DAA57449E91 for <patchwork@ffaux-bg.ffmpeg.org>; Sun, 13 Sep 2020 05:58:36 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id C34CD68BBDE; Sun, 13 Sep 2020 05:58:36 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 951A568BBCA for <ffmpeg-devel@ffmpeg.org>; Sun, 13 Sep 2020 05:58:24 +0300 (EEST) Received: by mail-wr1-f65.google.com with SMTP id w5so15041757wrp.8 for <ffmpeg-devel@ffmpeg.org>; Sat, 12 Sep 2020 19:58:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=GRyLUO4Q7jnyX/5fACKw9CpAvYX71nRpXyhfLqqPCwc=; b=lSfWRTJK9BiCYPAkgq4b+Xs7NfDeSI5QXn5xSm6HjBf5bLJXGwyF0BvgtJ0qFaL0IT CR1LZhhIb1ZOipCBamk0kfLGT2PQ89XeDaBXdd2Qk/r8P9E87WZkYwcBgrXsALvKdORZ 3ZWf7grT5czKMMqNo43G3SwUxnzvX3ZLTRbIfzJK2iepCMGjdPASFLr6quAlXpqXsOgy Y3j7O+QeSQV0RwBckiL0ld71mCfjsAPfPVQYnjh218rm8AZT83b8ykXHWHN36mEHYHCs /U5LCCJWmgVEohYuspPq+K/fh+KOVnrQKpOZVNsh/tl2PLwitS7HSvEpXyNF/cafT8ta xF4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=GRyLUO4Q7jnyX/5fACKw9CpAvYX71nRpXyhfLqqPCwc=; b=iJhT6e3cC+Ad/JlvjuQiPwzIH6Q+5MaNlim30jZlbVpKMpqTfNSPSb6CPBENZtBF4D POaoN6ITVek+wHHgCoUfaU71Fjz5c6xH8pjyPaL9jNwMFpo6Q1lqlP4sxs0glzLYFDlU ls45qkkPH9uxcpi/DI/Im/kHTuZne3oCmNVxrsr0VyIU/V7YfdLXJcqBc4P571zTeavU F6kCIuaZi7O64/HYx/7P56DgwqbQtpQh6XHw5Ez4rr/icWk1Uzh90vvv9saDGMMa/PxH bKQw81Hpij0HtZIvZ004Bf1u70jIoXTu1OYCQqrF8Pd42mPvxv4qVS2lMayeBRYSU4Dq WGwg== X-Gm-Message-State: AOAM532CsrE8nWWs15u+Hll72y5XzqbRJk63Q+P0vwqRnhObryrF7cDk X2xOzMMryRI4hduT6aVc/uZiJxY4a1M= X-Google-Smtp-Source: ABdhPJwAK1WLizuc7cDvxEqH2wo16vqrXt0BrDZHEKV3PL5yABzg2HDWyiZCD5ksi80yb9ExdLrODQ== X-Received: by 2002:adf:f2d0:: with SMTP id d16mr8740902wrp.332.1599965903855; Sat, 12 Sep 2020 19:58:23 -0700 (PDT) Received: from sblaptop.fritz.box (ipbcc1fb0f.dynamic.kabel-deutschland.de. [188.193.251.15]) by smtp.gmail.com with ESMTPSA id f3sm11883355wmb.35.2020.09.12.19.58.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 12 Sep 2020 19:58:23 -0700 (PDT) From: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> To: ffmpeg-devel@ffmpeg.org Date: Sun, 13 Sep 2020 04:57:42 +0200 Message-Id: <20200913025753.274772-5-andreas.rheinhardt@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200913025753.274772-1-andreas.rheinhardt@gmail.com> References: <20200913025753.274772-1-andreas.rheinhardt@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 05/16] avcodec/ra144enc: Don't free unnecessarily X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches <ffmpeg-devel.ffmpeg.org> List-Unsubscribe: <https://ffmpeg.org/mailman/options/ffmpeg-devel>, <mailto:ffmpeg-devel-request@ffmpeg.org?subject=unsubscribe> List-Archive: <https://ffmpeg.org/pipermail/ffmpeg-devel> List-Post: <mailto:ffmpeg-devel@ffmpeg.org> List-Help: <mailto:ffmpeg-devel-request@ffmpeg.org?subject=help> List-Subscribe: <https://ffmpeg.org/mailman/listinfo/ffmpeg-devel>, <mailto:ffmpeg-devel-request@ffmpeg.org?subject=subscribe> Reply-To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Cc: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" <ffmpeg-devel-bounces@ffmpeg.org> |
Series |
[FFmpeg-devel,01/16] avcodec/snowdec: Use ff_snow_common_init() directly
|
expand
|
Context | Check | Description |
---|---|---|
andriy/default | pending | |
andriy/make | success | Make finished |
andriy/make_fate | success | Make fate finished |
diff --git a/libavcodec/ra144enc.c b/libavcodec/ra144enc.c index 059f582334..c6965c5c47 100644 --- a/libavcodec/ra144enc.c +++ b/libavcodec/ra144enc.c @@ -65,14 +65,11 @@ static av_cold int ra144_encode_init(AVCodecContext * avctx) ret = ff_lpc_init(&ractx->lpc_ctx, avctx->frame_size, LPC_ORDER, FF_LPC_TYPE_LEVINSON); if (ret < 0) - goto error; + return ret; ff_af_queue_init(avctx, &ractx->afq); return 0; -error: - ra144_encode_close(avctx); - return ret; }
The init function of the real_144 encoder calls its own close function if a call to ff_lpc_init() fails; yet nothing has been allocated before that point and ff_lpc_init() can be expected to clean up after itself on error (the documentation does not say anything to the contrary and the current implementation can only fail if the only allocation fails, so there is nothing to clean up on error anyway), so this is unnecessary. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> --- libavcodec/ra144enc.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)