[FFmpeg-cvslog] avfilter/af_aecho: free input frame after it is being used
Paul B Mahol
git at videolan.org
Thu Nov 7 20:07:30 CET 2013
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Thu Nov 7 17:45:47 2013 +0000| [d9d752cfb55c445331fd9947100b15e87f65a42d] | committer: Paul B Mahol
avfilter/af_aecho: free input frame after it is being used
Signed-off-by: Paul B Mahol <onemda at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d9d752cfb55c445331fd9947100b15e87f65a42d
---
libavfilter/af_aecho.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libavfilter/af_aecho.c b/libavfilter/af_aecho.c
index 9c86f8d..8355e8c 100644
--- a/libavfilter/af_aecho.c
+++ b/libavfilter/af_aecho.c
@@ -285,10 +285,11 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
s->echo_samples(s, s->delayptrs, frame->extended_data, out_frame->extended_data,
frame->nb_samples, inlink->channels);
+ s->next_pts = frame->pts + av_rescale_q(frame->nb_samples, (AVRational){1, inlink->sample_rate}, inlink->time_base);
+
if (frame != out_frame)
av_frame_free(&frame);
- s->next_pts = frame->pts + av_rescale_q(frame->nb_samples, (AVRational){1, inlink->sample_rate}, inlink->time_base);
return ff_filter_frame(ctx->outputs[0], out_frame);
}
More information about the ffmpeg-cvslog
mailing list