From cda841a40e4e57d0619671eef85ea375e33c4e66 Mon Sep 17 00:00:00 2001 From: Sampo Savolainen Date: Mon, 26 Mar 2007 19:12:39 +0000 Subject: [PATCH] The traditional LAC2007 final dinner fix. This fix was written in a 24/7 bar/cafe in Berlin at 02:40AM . Thanks to Pau for the bug report. Oh yeah, it fixes crashes when removing inserts which had a gui instantiated. git-svn-id: svn://localhost/ardour2/trunk@1639 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/io_selector.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gtk2_ardour/io_selector.cc b/gtk2_ardour/io_selector.cc index 7ff12612e6..b097e8966b 100644 --- a/gtk2_ardour/io_selector.cc +++ b/gtk2_ardour/io_selector.cc @@ -778,14 +778,15 @@ PortInsertWindow::PortInsertWindow (Session& sess, boost::shared_ptr rescan_button.signal_clicked().connect (mem_fun(*this, &PortInsertWindow::rescan)); signal_delete_event().connect (bind (sigc::ptr_fun (just_hide_it), reinterpret_cast (this))); - pi->GoingAway.connect (mem_fun(*this, &PortInsertWindow::plugin_going_away)); + + going_away_connection = pi->GoingAway.connect (mem_fun(*this, &PortInsertWindow::plugin_going_away)); } void PortInsertWindow::plugin_going_away () { ENSURE_GUI_THREAD(mem_fun(*this, &PortInsertWindow::plugin_going_away)); - + going_away_connection.disconnect (); delete_when_idle (this); }