From cad3e2f054c5aeb6455f08bbe7b1d4aed7fb58af Mon Sep 17 00:00:00 2001 From: reuk Date: Wed, 22 Oct 2025 17:18:58 +0100 Subject: [PATCH] LV2 Client: Avoid potential nullptr deref when widget is not set by client UI --- .../format_types/juce_LV2PluginFormat.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/juce_audio_processors/format_types/juce_LV2PluginFormat.cpp b/modules/juce_audio_processors/format_types/juce_LV2PluginFormat.cpp index da6bde1cf1..cf35877882 100644 --- a/modules/juce_audio_processors/format_types/juce_LV2PluginFormat.cpp +++ b/modules/juce_audio_processors/format_types/juce_LV2PluginFormat.cpp @@ -213,6 +213,9 @@ public: Rectangle getDetectedViewBounds() const { + if (widget == nullptr) + return {}; + #if JUCE_MAC const auto frame = [(NSView*) widget frame]; return { (int) frame.size.width, (int) frame.size.height };