[FFmpeg-devel] [mov] Increment stsd_count while processing stsd data; avoids leaks.

Michael Niedermayer michael at niedermayer.cc
Wed Nov 22 14:05:16 EET 2017


On Tue, Nov 21, 2017 at 03:42:40PM -0800, Dale Curtis wrote:
> In the event of ff_mov_read_stsd_entries() failure, sc->stsd_count
> is not updated, even if the function allocates extradata memory.
> Instead update the sc->stsd_count as entries are parsed so that
> mov_read_close() can do the right thing.
> 
> Signed-off-by: Dale Curtis <dalecurtis at chromium.org>

>  mov.c |    7 ++++---
>  1 file changed, 4 insertions(+), 3 deletions(-)
> 4e5dd3d8a96401f9e1e79008ed4655d8896dbd21  fix_stsd_leak_v1.patch
> From 3c69f724173582f48189a92c3116a6783e078961 Mon Sep 17 00:00:00 2001
> From: Dale Curtis <dalecurtis at chromium.org>
> Date: Tue, 21 Nov 2017 15:40:22 -0800
> Subject: [PATCH] [mov] Increment stsd_count while processing stsd data; avoids
>  leaks.
> 
> In the event of ff_mov_read_stsd_entries() failure, sc->stsd_count
> is not updated, even if the function allocates extradata memory.
> Instead update the sc->stsd_count as entries are parsed so that
> mov_read_close() can do the right thing.
> 
> Signed-off-by: Dale Curtis <dalecurtis at chromium.org>

applied

thx

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

It is dangerous to be right in matters on which the established authorities
are wrong. -- Voltaire
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20171122/f468ca9e/attachment.sig>


More information about the ffmpeg-devel mailing list