[FFmpeg-devel] [PATCH 5/6] Add suppoort for using libklvanc from within decklink capture module

Devin Heitmueller dheitmueller at ltnglobal.com
Wed Nov 29 21:20:05 EET 2017


Hello James,

Thanks for reviewing.

>> +    afd[0] = pkt->hdr.payload[0] >> 3;
>> +    if (av_packet_add_side_data(cb_ctx->pkt, AV_PKT_DATA_AFD, afd, 1) < 0)
>> +        av_free(afd);
> 
> For this, av_packet_new_side_data() seems more adequate than av_malloc()
> + av_packet_add_side_data().
> 
> Also, you should propagate the errors av_packet_{add,new}_side_data return.

Good catch.  Yes, I will move to using av_packet_new_side_data() and fix the return.

Thanks,

Devin



More information about the ffmpeg-devel mailing list