Commit 7163c4b9 authored by Tristan Matthews's avatar Tristan Matthews Committed by Rémi Denis-Courmont

opus: update i_buffer when memmoving decoder output

Fixes #9343
Signed-off-by: default avatarRémi Denis-Courmont <remi@remlab.net>
parent d0b93ce7
......@@ -404,10 +404,12 @@ static block_t *DecodePacket( decoder_t *p_dec, ogg_packet *p_oggpacket,
}
if( spp > i_nb_samples )
{
p_aout_buffer->i_buffer = (i_nb_samples - i_end_trim) *
p_sys->header.channels * sizeof(float);
memmove(p_aout_buffer->p_buffer,
p_aout_buffer->p_buffer
+ (spp - i_nb_samples)*p_sys->header.channels*sizeof(float),
(i_nb_samples - i_end_trim)*p_sys->header.channels*sizeof(float));
p_aout_buffer->i_buffer);
}
i_nb_samples -= i_end_trim;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment