summaryrefslogtreecommitdiff
path: root/fftools/ffmpeg.c
diff options
context:
space:
mode:
Diffstat (limited to 'fftools/ffmpeg.c')
-rw-r--r--fftools/ffmpeg.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
index f8b02a8871..842ed2fa66 100644
--- a/fftools/ffmpeg.c
+++ b/fftools/ffmpeg.c
@@ -556,10 +556,9 @@ static void ffmpeg_cleanup(int ret)
of_close(&output_files[i]);
free_input_threads();
- for (i = 0; i < nb_input_files; i++) {
- avformat_close_input(&input_files[i]->ctx);
- av_freep(&input_files[i]);
- }
+ for (i = 0; i < nb_input_files; i++)
+ ifile_close(&input_files[i]);
+
for (i = 0; i < nb_input_streams; i++) {
InputStream *ist = input_streams[i];