Message ID | 20200322034756.29907-15-andreas.rheinhardt@gmail.com |
---|---|
State | Superseded |
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 985F244BCD9 for <patchwork@ffaux-bg.ffmpeg.org>; Sun, 22 Mar 2020 05:48:50 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 83E5268B59B; Sun, 22 Mar 2020 05:48:50 +0200 (EET) 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 8705368B520 for <ffmpeg-devel@ffmpeg.org>; Sun, 22 Mar 2020 05:48:43 +0200 (EET) Received: by mail-wr1-f65.google.com with SMTP id w10so12306130wrm.4 for <ffmpeg-devel@ffmpeg.org>; Sat, 21 Mar 2020 20:48:43 -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=c/cLo8p4OjrRQdTgdgiKWOSuvdE0j/YdVQdvqmVRA74=; b=ivwSShjPKZJKK204uuIuIbA/8RV+WnWo4GlSwsf7V5ljrEwD2VqeG2MWLQK6SW68GB hWQptT+NrqrlQdyfwmXT2Y3YtaZ6BBqOQ1kG9JesfhtyUmWhKJHLLb9BxDf3gw8yIUKb q1wWQFahB8HbYrYO05fGrg8ifdl8OQQ3CQ2aimJUUp4bZog3YMCor9qe+HNOJ0BEM9va 7MjkPxi4j6tnsfgLywr4WIgLC/xMBkeolofniOEBYSJvyWFvh6K/PAm+B1QZh+ThLIhQ vB6+iMZCzPIPKUFFeJuzoMK7rLF4mCz4F3AHdSZbRZYpurtKWmF/YauDmZQx7svSzMfc QynA== 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=c/cLo8p4OjrRQdTgdgiKWOSuvdE0j/YdVQdvqmVRA74=; b=mYtAEgjAS8aAzCTN8TMArlA5XbCJxHdXSW95SQsn1bSN772NzCMvg0STUk1mpCO8UW bTHPBPwEW/SCTKyx7yzMxiZ2IxnNsOqC+nes9ElAtJRf4Lm7TI0DBxddeZGmDYH15fyq UQOAkxC79pFT8GKdr3rJbS/cB18V6jojdYsGU9Fqp3MqA8ChGyEyW4c7/+p1xJR8pXq+ kGjrLArVqNxeVd+MnpEYwIHvmR2x7UbJZ6aDYIM75lO8sLqK5UmZPyix+FZWA0ufRVUN sKLP3R0B8j1SvzhoIcsKc9ojLadqwoQIhXVDCEGxyoXThb+SOksnm41ADUCX+drx2AE6 2x/w== X-Gm-Message-State: ANhLgQ3fxRihVcMGsF/78GwFcCnSyjoOGPMCANVQ4Z2SflEi630u3qpU FIjeXtWXKrfXwa1GC7+WGdejxYY+ X-Google-Smtp-Source: ADFU+vtYJmNG/e2s8BTjT2UW7CQu+Ck7lm7ISkcafTOr+ApFYfXekl7kDKX0OQhzhrec8VgI3aC7qQ== X-Received: by 2002:a5d:6a4b:: with SMTP id t11mr20891611wrw.52.1584848922575; Sat, 21 Mar 2020 20:48:42 -0700 (PDT) Received: from sblaptop.fritz.box (ipbcc1ab57.dynamic.kabel-deutschland.de. [188.193.171.87]) by smtp.gmail.com with ESMTPSA id k204sm1530371wma.17.2020.03.21.20.48.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Mar 2020 20:48:41 -0700 (PDT) From: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> To: ffmpeg-devel@ffmpeg.org Date: Sun, 22 Mar 2020 04:47:50 +0100 Message-Id: <20200322034756.29907-15-andreas.rheinhardt@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200322034756.29907-1-andreas.rheinhardt@gmail.com> References: <20200322034756.29907-1-andreas.rheinhardt@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 15/21] avformat/ape: Fix memleaks upon read_header failure 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/21] avformat/nsvdec: Use av_packet_move_ref() for packet ownership transfer
|
expand
|
Context | Check | Description |
---|---|---|
andriy/ffmpeg-patchwork | success | Make fate finished |
diff --git a/libavformat/ape.c b/libavformat/ape.c index ed6752a415..81088bbc02 100644 --- a/libavformat/ape.c +++ b/libavformat/ape.c @@ -470,4 +470,5 @@ AVInputFormat ff_ape_demuxer = { .read_close = ape_read_close, .read_seek = ape_read_seek, .extensions = "ape,apl,mac", + .flags_internal = FF_INPUTFORMAT_HEADER_CLEANUP, };
Several buffers allocated in the course of reading the header would leak if an error happened after their allocation. Fix this by setting the FF_INPUTFORMAT_HEADER_CLEANUP flag so that ape_read_close() will be called to clean up in case of failure to read the header. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> --- libavformat/ape.c | 1 + 1 file changed, 1 insertion(+)