From 7f8c19799d0c60c29facbbff9ee1914d1bb2059b Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Fri, 11 Feb 2022 07:10:31 -0800 Subject: [PATCH] Fix a very serious error resampling short files Files that are so short that they need both pre- and post-extrapolation at the same time. Signed-off-by: Christopher Snowhill --- Audio/Chain/ConverterNode.m | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Audio/Chain/ConverterNode.m b/Audio/Chain/ConverterNode.m index 4872ad889..5820fa570 100644 --- a/Audio/Chain/ConverterNode.m +++ b/Audio/Chain/ConverterNode.m @@ -785,7 +785,9 @@ tryagain: latencyEaten -= outputDone; outputDone = 0; } - } else if(latencyEatenPost) { + } + + if(latencyEatenPost) { if(outputDone > latencyEatenPost) { outputDone -= latencyEatenPost; } else {