You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avcodec/decode: don't reject flush packets when buffer_pkt is not empty
Restores the behavior before commit a92dbeb9ae
.
Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
@@ -666,10 +666,9 @@ int attribute_align_arg avcodec_send_packet(AVCodecContext *avctx, const AVPacke
|
|||||||
if (avpkt && !avpkt->size && avpkt->data)
|
if (avpkt && !avpkt->size && avpkt->data)
|
||||||
return AVERROR(EINVAL);
|
return AVERROR(EINVAL);
|
||||||
|
|
||||||
if (!AVPACKET_IS_EMPTY(avci->buffer_pkt))
|
|
||||||
return AVERROR(EAGAIN);
|
|
||||||
|
|
||||||
if (avpkt && (avpkt->data || avpkt->side_data_elems)) {
|
if (avpkt && (avpkt->data || avpkt->side_data_elems)) {
|
||||||
|
if (!AVPACKET_IS_EMPTY(avci->buffer_pkt))
|
||||||
|
return AVERROR(EAGAIN);
|
||||||
ret = av_packet_ref(avci->buffer_pkt, avpkt);
|
ret = av_packet_ref(avci->buffer_pkt, avpkt);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
Reference in New Issue
Block a user