From db79d0417396edc7ed0fc4fa438daa9526306fdf Mon Sep 17 00:00:00 2001 From: Stefano Sabatini Date: Sat, 17 Sep 2011 01:18:53 +0200 Subject: [PATCH] af_aresample: do not request a buffer with AV_PERM_REUSE2 permissions in filter_samples() That was pointless. Simplify. --- libavfilter/af_aresample.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libavfilter/af_aresample.c b/libavfilter/af_aresample.c index 04188c854d..9af50cf208 100644 --- a/libavfilter/af_aresample.c +++ b/libavfilter/af_aresample.c @@ -268,10 +268,8 @@ static void filter_samples(AVFilterLink *inlink, AVFilterBufferRef *insamplesref if (aresample->outsamplesref) avfilter_unref_buffer(aresample->outsamplesref); - aresample->outsamplesref = avfilter_get_audio_buffer(outlink, - AV_PERM_WRITE | AV_PERM_REUSE2, - requested_out_nb_samples); - + aresample->outsamplesref = + avfilter_get_audio_buffer(outlink, AV_PERM_WRITE, requested_out_nb_samples); avfilter_copy_buffer_ref_props(aresample->outsamplesref, insamplesref); aresample->outsamplesref->pts = insamplesref->pts / inlink->sample_rate * outlink->sample_rate;