You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-07-06 06:27:36 +02:00
avcodec/libwebpenc_animencoder: stop propagating bogus empty packets
Packets must have at least one of data or side_data. If none are available, then got_packet must not be signaled. The generic encode code already discarded these empty packets, but it's better just not propagating them at all. Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
@ -102,10 +102,9 @@ static int libwebp_anim_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
pkt->pts = pkt->dts = frame->pts;
|
|
||||||
s->prev_frame_pts = frame->pts; // Save for next frame.
|
s->prev_frame_pts = frame->pts; // Save for next frame.
|
||||||
ret = 0;
|
ret = 0;
|
||||||
*got_packet = 1;
|
*got_packet = 0;
|
||||||
|
|
||||||
end:
|
end:
|
||||||
WebPPictureFree(pic);
|
WebPPictureFree(pic);
|
||||||
|
Reference in New Issue
Block a user