Hi Jules,
I can reproduce a crash when I use the current (e.g. current tip) JuceDemoPlugin’s TextInput of a slider and afterwards close the plugin’s GUI. As far as I could debug this it seems that one component gives back an invalid parent pointer (possibleChild->parentComponent_) in the loop in Component::isParentOf() causing the EXC_BAD_ACCESS exception in the next cycle. I tried this with Cubase, Live and Reaper which all crash when using the VST. The AU doesn’t crash though (in Reaper and Live).
I have an older JuceDemoPlugin which doesn’t crash. Unfortunatly it doesn’t show the JUCE version in auval, so I’m not sure which version exactly. It was build on Dec. 3rd, it should be a tip around this time.
The crashlog:
Exception Type: EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x0000000000000022
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Thread 0 Crashed: Dispatch queue: com.apple.main-thread
0 ...rialsoftware.JuceDemoPlugin 0x1dfe0045 juce::Component::isParentOf(juce::Component const*) const + 11 (juce_Component.cpp:1439)
1 ...rialsoftware.JuceDemoPlugin 0x1e05d7e2 juce::Component::~Component() + 152 (juce_Component.cpp:418)
2 ...rialsoftware.JuceDemoPlugin 0x1e06ae63 juce::Slider::~Slider() + 983 (juce_Slider.cpp:145)
3 ...rialsoftware.JuceDemoPlugin 0x1e02baf3 juce::Component::deleteAllChildren() + 65 (juce_Component.cpp:1405)
4 ...rialsoftware.JuceDemoPlugin 0x1de0a930 JuceDemoPluginAudioProcessorEditor::~JuceDemoPluginAudioProcessorEditor() + 78 (PluginEditor.cpp:57)
5 ...rialsoftware.JuceDemoPlugin 0x1e02baf3 juce::Component::deleteAllChildren() + 65 (juce_Component.cpp:1405)
6 ...rialsoftware.JuceDemoPlugin 0x1e1ae9dd JuceVSTWrapper::EditorCompWrapper::~EditorCompWrapper() + 61 (juce_VST_Wrapper.cpp:1301)
7 ...rialsoftware.JuceDemoPlugin 0x1e1a95ea juce::ScopedPointer<JuceVSTWrapper::EditorCompWrapper>::operator=(JuceVSTWrapper::EditorCompWrapper*) + 56 (juce_amalgamated.h:6950)
8 ...rialsoftware.JuceDemoPlugin 0x1e1ab0f9 JuceVSTWrapper::deleteEditor(bool) + 407 (juce_VST_Wrapper.cpp:1114)
9 ...rialsoftware.JuceDemoPlugin 0x1e1ab2c3 JuceVSTWrapper::timerCallback() + 57 (juce_VST_Wrapper.cpp:999)
10 ...rialsoftware.JuceDemoPlugin 0x1dfd61b2 juce::InternalTimerThread::callTimers() + 136 (juce_Timer.cpp:137)
11 ...rialsoftware.JuceDemoPlugin 0x1dfd630d juce::InternalTimerThread::handleMessage(juce::Message const&) + 17 (juce_Timer.cpp:154)
12 ...rialsoftware.JuceDemoPlugin 0x1df05944 juce::MessageManager::deliverMessage(juce::Message*) + 206 (juce_MessageManager.cpp:125)
13 ...rialsoftware.JuceDemoPlugin 0x1e1a0492 juce::AppDelegateRedirector::runLoopCallback() + 82 (juce_mac_MessageManager.mm:162)
14 ...rialsoftware.JuceDemoPlugin 0x1e1a050b juce::AppDelegateRedirector::runLoopSourceCallback(void*) + 17 (juce_mac_MessageManager.mm:173)
Chris