From 70cf1c0be3b4a68e6042057d9256cdcfbe363c9e Mon Sep 17 00:00:00 2001 From: Paul Ferrand Date: Fri, 7 Aug 2020 11:19:33 +0200 Subject: [PATCH] Assert rather than return --- src/sfizz/Synth.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/sfizz/Synth.cpp b/src/sfizz/Synth.cpp index dc2e0596..6081ba2b 100644 --- a/src/sfizz/Synth.cpp +++ b/src/sfizz/Synth.cpp @@ -680,8 +680,7 @@ void sfz::Synth::setSampleRate(float sampleRate) noexcept void sfz::Synth::renderVoiceToOutputs(Voice& voice, AudioSpan& tempSpan) noexcept { const Region* region = voice.getRegion(); - if (region == nullptr) - return; + ASSERT(region != nullptr); voice.renderBlock(tempSpan); for (size_t i = 0, n = effectBuses.size(); i < n; ++i) {