[SCM] libav/master: lavr: allocate the resampling buffer with a positive size

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun May 4 21:36:33 UTC 2014


The following commit has been merged in the master branch:
commit dccac759d39e761398d3d4172ae0b98c0186efa5
Author: Anton Khirnov <anton at khirnov.net>
Date:   Thu Mar 20 20:40:24 2014 +0100

    lavr: allocate the resampling buffer with a positive size
    
    This fixes cases where very few input samples (fewer than needed for one
    output sample) are passed to lavr at the beginning.
    CC:libav-stable at libav.org
    (cherry picked from commit ac976ed91e323754e9a84509873ebdb437372797)

diff --git a/libavresample/utils.c b/libavresample/utils.c
index 36d9d04..bf2eaf2 100644
--- a/libavresample/utils.c
+++ b/libavresample/utils.c
@@ -117,7 +117,7 @@ int avresample_open(AVAudioResampleContext *avr)
     }
     if (avr->resample_needed) {
         avr->resample_out_buffer = ff_audio_data_alloc(avr->out_channels,
-                                                       0, avr->internal_sample_fmt,
+                                                       1024, avr->internal_sample_fmt,
                                                        "resample_out_buffer");
         if (!avr->resample_out_buffer) {
             ret = AVERROR(EINVAL);

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list