From cf4532967decf7c9627f48e9f7ff9824947928a4 Mon Sep 17 00:00:00 2001 From: reuk Date: Wed, 19 Apr 2023 14:23:50 +0100 Subject: [PATCH] AudioProcessor: Only warn once if any parameter version hint is zero --- .../juce_audio_processors/processors/juce_AudioProcessor.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/juce_audio_processors/processors/juce_AudioProcessor.cpp b/modules/juce_audio_processors/processors/juce_AudioProcessor.cpp index 64aaf531f0..fec7e9cc53 100644 --- a/modules/juce_audio_processors/processors/juce_AudioProcessor.cpp +++ b/modules/juce_audio_processors/processors/juce_AudioProcessor.cpp @@ -437,7 +437,9 @@ void AudioProcessor::validateParameter (AudioProcessorParameter* param) See the documentation for AudioProcessorParameter(int) for more information. */ #if JucePlugin_Build_AU - jassert (wrapperType == wrapperType_Undefined || param->getVersionHint() != 0); + static std::once_flag flag; + if (wrapperType == wrapperType_Undefined || param->getVersionHint() != 0) + std::call_once (flag, [] { jassertfalse; }); #endif }