diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-06-15 00:49:02 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-06-23 18:17:43 +0200 |
commit | c2b72eac6cfe5170c27db98cbc940540a91e3802 (patch) | |
tree | 9fd9e4fb3d0d9098d9f43c39c4c80039bed92bbf | |
parent | 9d77a6293627663d5052d05697303b53efd5d220 (diff) | |
download | ffmpeg-c2b72eac6cfe5170c27db98cbc940540a91e3802.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>
-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 b0f6f533e1..a46919ba36 100644 --- a/libavformat/mpc.c +++ b/libavformat/mpc.c @@ -153,7 +153,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; |