use proper audio buffer truncation function