Commit f90c9c30 authored by Michael Niedermayer's avatar Michael Niedermayer

Check av_dup_packet() return code

Fixes: CID1338320
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 39c0b22d
......@@ -89,7 +89,9 @@ static void * attribute_align_arg worker(void *v){
pthread_mutex_unlock(&c->buffer_mutex);
av_frame_free(&frame);
if(got_packet) {
av_dup_packet(pkt);
int ret2 = av_dup_packet(pkt);
if (ret >= 0 && ret2 < 0)
ret = ret2;
} else {
pkt->data = NULL;
pkt->size = 0;
......
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