From f7813a5324be39d13ab536c245d15dfc602a7849 Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Sun, 29 Dec 2013 12:19:38 +0000 Subject: basic type mechanism working --- ffmpeg/libavformat/rtpdec_qdm2.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'ffmpeg/libavformat/rtpdec_qdm2.c') diff --git a/ffmpeg/libavformat/rtpdec_qdm2.c b/ffmpeg/libavformat/rtpdec_qdm2.c index 6ce776d..e1dd62f 100644 --- a/ffmpeg/libavformat/rtpdec_qdm2.c +++ b/ffmpeg/libavformat/rtpdec_qdm2.c @@ -29,6 +29,7 @@ #include "libavutil/avassert.h" #include "libavutil/intreadwrite.h" #include "libavcodec/avcodec.h" +#include "internal.h" #include "rtp.h" #include "rtpdec.h" #include "rtpdec_formats.h" @@ -104,9 +105,7 @@ static int qdm2_parse_config(PayloadContext *qdm, AVStream *st, if (item_len < 30) return AVERROR_INVALIDDATA; av_freep(&st->codec->extradata); - st->codec->extradata_size = 26 + item_len; - if (!(st->codec->extradata = av_mallocz(st->codec->extradata_size + FF_INPUT_BUFFER_PADDING_SIZE))) { - st->codec->extradata_size = 0; + if (ff_alloc_extradata(st->codec, 26 + item_len)) { return AVERROR(ENOMEM); } AV_WB32(st->codec->extradata, 12); -- cgit v1.2.3