Commit c5ddadd4 authored by Maik Scholz's avatar Maik Scholz Committed by Sebastian Dröge

audioresample: Don't produce more data than expected in GAP mode

Due to rounding errors in combination with rate changes, we might otherwise
end up producing too much and run into an assertion later.

This is not a problem with the new audioresample in GIT master.
parent 793ef9e6
......@@ -1056,6 +1056,11 @@ gst_audio_resample_process (GstAudioResample * resample, GstBuffer * inbuf,
out_processed = 0;
/* take care that out_processed is not greater then out_len */
if (out_processed > out_len) {
out_processed = out_len;
memset (, 0, out_map.size);
resample->num_gap_samples += in_len;
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