You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
Add missing av_free_packet.
Fixes memory leak when encoding at least with mpegvideo using the new encode2 function. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
This commit is contained in:
1
ffmpeg.c
1
ffmpeg.c
@@ -1633,6 +1633,7 @@ static void do_video_out(AVFormatContext *s, OutputStream *ost,
|
|||||||
write_frame(s, &pkt, ost);
|
write_frame(s, &pkt, ost);
|
||||||
frame_size = pkt.size;
|
frame_size = pkt.size;
|
||||||
video_size += pkt.size;
|
video_size += pkt.size;
|
||||||
|
av_free_packet(&pkt);
|
||||||
|
|
||||||
/* if two pass, output log */
|
/* if two pass, output log */
|
||||||
if (ost->logfile && enc->stats_out) {
|
if (ost->logfile && enc->stats_out) {
|
||||||
|
Reference in New Issue
Block a user