Commit 3b4026e1 authored by Yusuke Nakamura's avatar Yusuke Nakamura Committed by James Almer

avpacket: reset dst side_data fields in av_packet_copy_props

This effectively copies the side data elements from src instead of
potentially merging them with those already existing in dst.
This by extension also removes the only dependency on existing values
in the dst packet.
Reviewed-by: 's avatarwm4 <nfxjfg@googlemail.com>
Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent 7c82e0f6
......@@ -571,6 +571,8 @@ FF_ENABLE_DEPRECATION_WARNINGS
dst->flags = src->flags;
dst->stream_index = src->stream_index;
dst->side_data = NULL;
dst->side_data_elems = 0;
for (i = 0; i < src->side_data_elems; i++) {
enum AVPacketSideDataType type = src->side_data[i].type;
int size = src->side_data[i].size;
......
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