diff --git a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp index a6f10a49aa..abfd44d55b 100644 --- a/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp @@ -1873,10 +1873,10 @@ public: { if (processor != nullptr) { - const double currentSampleRate = getSampleRate(); + const double sampleRate = getSampleRate(); - if (currentSampleRate > 0.0) - return jlimit (0, 0x7fffffff, (int) processor->getTailSamples()) / currentSampleRate; + if (sampleRate > 0.0) + return jlimit (0, 0x7fffffff, (int) processor->getTailSamples()) / sampleRate; } return 0.0; diff --git a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp index 6c1a38becd..67735cd044 100644 --- a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp @@ -900,13 +900,13 @@ public: if (effect == nullptr) return 0.0; - const double currentSampleRate = getSampleRate(); + const double sampleRate = getSampleRate(); - if (currentSampleRate <= 0) + if (sampleRate <= 0) return 0.0; VstIntPtr samples = dispatch (effGetTailSize, 0, 0, 0, 0); - return samples / currentSampleRate; + return samples / sampleRate; } bool acceptsMidi() const override { return wantsMidiMessages; }