Commit 86a9370e authored by Michael Niedermayer's avatar Michael Niedermayer

avformat/mpc: attempt to allocate a packet that is not smaller than the data inside it

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent ada8f9c0
......@@ -152,7 +152,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;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment