diff --git a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp index 35293b8b1c..85dfb785cc 100644 --- a/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp @@ -2796,7 +2796,11 @@ public: Vst2::ERect* rect = nullptr; dispatch (Vst2::effEditGetRect, 0, 0, &rect, 0); - setSize (rect->right - rect->left, rect->bottom - rect->top); + + if (rect != nullptr) + setSize (rect->right - rect->left, rect->bottom - rect->top); + else + setSize (1, 1); setOpaque (true); setVisible (true);