diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-06-15 00:49:02 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-06-23 15:14:41 +0200 |
commit | 8f443e4f32c91dc2141b6d0c997a2fe03536e89c (patch) | |
tree | b8a57e1d94e57116fceeefe78d0b53ad7090f3e7 /libavformat/mpc.c | |
parent | f48d7abf40f3873016a9b27de89ec29b95947d28 (diff) | |
download | ffmpeg-8f443e4f32c91dc2141b6d0c997a2fe03536e89c.tar.gz |
avformat/mpc: attempt to allocate a packet that is not smaller than the data inside it
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 86a9370e2b91d67375e66a06d6eb573b5a017775)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/mpc.c')
-rw-r--r-- | libavformat/mpc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/mpc.c b/libavformat/mpc.c index 3b818ed146..b9368112fb 100644 --- a/libavformat/mpc.c +++ b/libavformat/mpc.c @@ -151,7 +151,7 @@ static int mpc_read_packet(AVFormatContext *s, AVPacket *pkt) } c->curbits = (curbits + size2) & 0x1F; - if ((ret = av_new_packet(pkt, size)) < 0) + if ((ret = av_new_packet(pkt, size + 4)) < 0) return ret; pkt->data[0] = curbits; |