You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avcodec/encode: silence a deprecation warning about av_init_packet()
No need to adapt this code as it will be removed long before av_init_packet() Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
@@ -462,7 +462,9 @@ static int compat_encode(AVCodecContext *avctx, AVPacket *avpkt,
|
||||
av_buffer_unref(&avpkt->buf);
|
||||
avpkt->buf = user_pkt.buf;
|
||||
avpkt->data = user_pkt.data;
|
||||
FF_DISABLE_DEPRECATION_WARNINGS
|
||||
av_init_packet(&user_pkt);
|
||||
FF_ENABLE_DEPRECATION_WARNINGS
|
||||
} else {
|
||||
av_log(avctx, AV_LOG_ERROR, "Provided packet is too small, needs to be %d\n", avpkt->size);
|
||||
av_packet_unref(avpkt);
|
||||
|
Reference in New Issue
Block a user