diff options
author | David Robillard <d@drobilla.net> | 2012-04-23 19:54:31 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-04-23 19:54:31 +0000 |
commit | 8b111ed224e999a2de057bb8f4669ddedfc3132e (patch) | |
tree | 7d014acc7082555f15bd86af24ee7d58eca6d57c /gtk2_ardour | |
parent | c9f09a10c4ed825c50e636b66844048e4f50e88e (diff) |
Fix crash when closing LV2 UIs.
git-svn-id: svn://localhost/ardour2/branches/3.0@12067 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour')
-rw-r--r-- | gtk2_ardour/lv2_plugin_ui.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gtk2_ardour/lv2_plugin_ui.cc b/gtk2_ardour/lv2_plugin_ui.cc index 7699f394d0..cacc24af66 100644 --- a/gtk2_ardour/lv2_plugin_ui.cc +++ b/gtk2_ardour/lv2_plugin_ui.cc @@ -310,18 +310,18 @@ LV2PluginUI::lv2ui_free() if (_gui_widget) { remove (*_gui_widget); + _gui_widget = NULL; } if (_ardour_buttons_box) { remove (*_ardour_buttons_box); - delete _ardour_buttons_box; - _ardour_buttons_box = 0; + _ardour_buttons_box = NULL; } - suil_instance_free((SuilInstance*)_inst); - - _inst = NULL; - _gui_widget = NULL; + if (_inst) { + suil_instance_free((SuilInstance*)_inst); + _inst = NULL; + } } LV2PluginUI::~LV2PluginUI () |