avfilter/aeval: free input frame on error

Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
Paul B Mahol 2017-05-12 21:42:21 +02:00
parent e312ed0504
commit c02921417b
1 changed files with 3 additions and 1 deletions

View File

@ -429,8 +429,10 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
/* do volume scaling in-place if input buffer is writable */
out = ff_get_audio_buffer(outlink, nb_samples);
if (!out)
if (!out) {
av_frame_free(&in);
return AVERROR(ENOMEM);
}
av_frame_copy_props(out, in);
t0 = TS2T(in->pts, inlink->time_base);