mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
bit: check av_new_packet() return value
Fixes CID703626. Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
ca28cb5f83
commit
adc61d68b0
@ -90,7 +90,8 @@ static int read_packet(AVFormatContext *s,
|
||||
if(ret != 8 * packet_size * sizeof(uint16_t))
|
||||
return AVERROR(EIO);
|
||||
|
||||
av_new_packet(pkt, packet_size);
|
||||
if (av_new_packet(pkt, packet_size) < 0)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
init_put_bits(&pbo, pkt->data, packet_size);
|
||||
for(j=0; j < packet_size; j++)
|
||||
|
Loading…
Reference in New Issue
Block a user