mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-12 18:31:37 +00:00
avformat/isom: Uninit layout in ff_mp4_read_dec_config_descr()
Fixes: memleak Fixes: 67442/clusterfuzz-testcase-minimized-ffmpeg_dem_CAF_fuzzer-5068813261406208 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
parent
e3984de6ff
commit
d157725cf7
@ -359,6 +359,7 @@ int ff_mp4_read_dec_config_descr(AVFormatContext *fc, AVStream *st, AVIOContext
|
|||||||
st->codecpar->extradata_size, 1, fc);
|
st->codecpar->extradata_size, 1, fc);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
av_channel_layout_uninit(&st->codecpar->ch_layout);
|
||||||
st->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC;
|
st->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC;
|
||||||
st->codecpar->ch_layout.nb_channels = cfg.channels;
|
st->codecpar->ch_layout.nb_channels = cfg.channels;
|
||||||
if (cfg.object_type == 29 && cfg.sampling_index < 3) // old mp3on4
|
if (cfg.object_type == 29 && cfg.sampling_index < 3) // old mp3on4
|
||||||
|
Loading…
Reference in New Issue
Block a user