diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2019-12-03 11:27:38 +0100 |
---|---|---|
committer | Steven Liu <lq@chinaffmpeg.org> | 2019-12-23 15:39:49 +0800 |
commit | 5b42d3357120a338e506acbd2a0081a0702aa166 (patch) | |
tree | d6fab55c15434c6d6e12f36dde9540a9e5190f7f | |
parent | 74a8be3546c54e109ca16639f9863a6cdcd9aead (diff) | |
download | ffmpeg-5b42d3357120a338e506acbd2a0081a0702aa166.tar.gz |
avformat/hls: Use av_packet_move_ref() for packet ownership transfer
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
-rw-r--r-- | libavformat/hls.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libavformat/hls.c b/libavformat/hls.c index 21353bbad7..f60396f246 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -2201,9 +2201,8 @@ static int hls_read_packet(AVFormatContext *s, AVPacket *pkt) ist = pls->ctx->streams[pls->pkt.stream_index]; st = pls->main_streams[pls->pkt.stream_index]; - *pkt = pls->pkt; + av_packet_move_ref(pkt, &pls->pkt); pkt->stream_index = st->index; - reset_packet(&c->playlists[minplaylist]->pkt); if (pkt->dts != AV_NOPTS_VALUE) c->cur_timestamp = av_rescale_q(pkt->dts, |