summaryrefslogtreecommitdiff
path: root/ffmpeg.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2011-02-01 20:02:17 +0100
committerMichael Niedermayer <michaelni@gmx.at>2011-02-06 20:31:42 +0100
commitab543afe47c5bc63622acce775189bb920638126 (patch)
tree66728e92d84dd52f924adf8c0b5daf05855d629f /ffmpeg.c
parentc68be8e135ddcd8a043142d26a5fdc4ef01b1218 (diff)
Make avfilter_graph_free() free the graph.
Make avfilter_graph_free() free not only the internal structures, but also the allocated graph, and set the graph pointer to NULL for increased safety. Simplify usage. Signed-off-by: Mans Rullgard <mans@mansr.com> (cherry picked from commit 4359288c565705d1734f63d277f8918ee5af5e54)
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index 60eca1a630..a5d7e26023 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -2708,10 +2708,7 @@ static int transcode(AVFormatContext **output_files,
}
}
#if CONFIG_AVFILTER
- if (graph) {
- avfilter_graph_free(graph);
- av_freep(&graph);
- }
+ avfilter_graph_free(&graph);
#endif
/* finished ! */