summaryrefslogtreecommitdiff
path: root/fftools/ffprobe.c
diff options
context:
space:
mode:
authorDerek Buitenhuis <derek.buitenhuis@gmail.com>2019-06-21 14:34:45 +0100
committerDerek Buitenhuis <derek.buitenhuis@gmail.com>2019-06-21 15:40:58 +0100
commitd5a6b390ced64cfd33764930f8b1d3c6437a43b6 (patch)
treef6c1fef4d1675f656acaa73f309778ed4cabbd49 /fftools/ffprobe.c
parentd70fece5609fa62db62c894d63bffc99aa677142 (diff)
ffprobe: Fix memory leak
This packet was not necessarily unreferenced. Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Diffstat (limited to 'fftools/ffprobe.c')
-rw-r--r--fftools/ffprobe.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c
index 3becb6330e..5aaddb0308 100644
--- a/fftools/ffprobe.c
+++ b/fftools/ffprobe.c
@@ -2429,9 +2429,7 @@ static int read_interval_packets(WriterContext *w, InputFile *ifile,
}
av_packet_unref(&pkt);
}
- av_init_packet(&pkt);
- pkt.data = NULL;
- pkt.size = 0;
+ av_packet_unref(&pkt);
//Flush remaining frames that are cached in the decoder
for (i = 0; i < fmt_ctx->nb_streams; i++) {
pkt.stream_index = i;