ffmpeg: properly cleanup filter graph on init failure
authorwm4 <nfxjfg@googlemail.com>
Thu, 2 Mar 2017 18:14:58 +0000 (19:14 +0100)
committerwm4 <nfxjfg@googlemail.com>
Fri, 3 Mar 2017 07:45:43 +0000 (08:45 +0100)
commit16abc10b0997c76cbb0c0ebedc49f6bc21452f9d
tree43c277d77fb039523a7f0810cd1e659c976fc528
parent7dd44cde2abb156710f26a08b6cd6c8dd9a9793d
ffmpeg: properly cleanup filter graph on init failure

The filter field is often used to check whether a filter is
configured. If configuring the filter actually fails somewhere in
the middle of it, these fields could still be set to non-NULL, which
lead to other code accessing the half-configured filter graph, which
in turn could lead to crashes within libavfilter.

Solve this by properly resetting all fields.

This was triggered by a fuzzed sample after the recent changes. It's
unknown whether this behavior could be triggered before that.
ffmpeg_filter.c