[vlc-devel] [PATCH] araw: fix passthrough copying
le.businessman at gmail.com
Mon Nov 11 18:01:42 CET 2013
On Mon, Nov 11, 2013 at 11:55 AM, Rafaël Carré <funman at videolan.org> wrote:
> Le 10/11/2013 17:29, Tristan Matthews a écrit :
>> Fixes #9343 where in->i_buffer is greater than in->i_nb_samples * sizeof(frame).
> In which case does this happen?
When clicking "fingerprint" while playing an opus file (as per
I guess the larger question is, why does in have a bigger buffer than
its sample count? I guess at some point the sample count or
buffer_count is being updated properly?
> BTW out->i_buffer is equivalent to
> in->i_nb_samples * enc->fmt_out.audio.i_bytes_per_frame
> which is used 2 times, worth having a variable for it?
Where is it used a second time? I see it once, and then
in->i_nb_samples * enc->fmt_out.audio.i_channels next to it.
>> modules/codec/araw.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>> diff --git a/modules/codec/araw.c b/modules/codec/araw.c
>> index 0d5c300..d4bd4b0 100644
>> --- a/modules/codec/araw.c
>> +++ b/modules/codec/araw.c
>> @@ -739,7 +739,7 @@ static block_t *Encode( encoder_t *enc, block_t *in )
>> encode( out->p_buffer, in->p_buffer, in->i_nb_samples
>> * enc->fmt_out.audio.i_channels );
>> - memcpy( out->p_buffer, in->p_buffer, in->i_buffer );
>> + memcpy( out->p_buffer, in->p_buffer, out->i_buffer );
>> return out;
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
More information about the vlc-devel