There’s certainly no leak in that method when it’s used normally.
But if you’ve hacked it together so that you’re sharing objects between DLLs and a host, then you’re on your own with any memory management problems you create, I’m afraid.
[quote=“jules”]It might be similar, but that doesn’t mean I can magically tell you why your code is leaking!
[/quote]
I didn’t expect you to magically know where my problem is. Sorry if it sounded like that!
Just thought since you wrote the vst wrapper maybe you had an idea why the memory COULD be leaking in this usecase.
I solved the leak. The problem was the point where I called the shutdownJuce_GUI(); function.
First I had it inside my PluginEditor Class and it was called whenever the editor was closed in its destructor.
Now I moved the call to my base plugin class, so it is only called when the plugin is destroyed and the leak is gone.
Not sure why, because only the pluginEditor class is using juce functions but at least the leak is gone