summaryrefslogtreecommitdiff
path: root/libs/ardour/session.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2016-04-24 02:51:23 +0200
committerRobin Gareus <robin@gareus.org>2016-04-24 02:53:01 +0200
commit4fe7d1ea08e364b3c0f69cae1a86c637e3cb1d77 (patch)
tree07628ddf9e8ffd3c26bc6458bd4020a39ca4410c /libs/ardour/session.cc
parentf317451609cf230bfb231224fc60d64625ef3273 (diff)
further tweaks to session close
Diffstat (limited to 'libs/ardour/session.cc')
-rw-r--r--libs/ardour/session.cc13
1 files changed, 11 insertions, 2 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index 3b03985ece..efc1665219 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -596,6 +596,7 @@ Session::destroy ()
/* disconnect from any and all signals that we are connected to */
+ Port::PortSignalDrop (); /* EMIT SIGNAL */
drop_connections ();
/* shutdown control surface protocols while we still have ports
@@ -616,7 +617,6 @@ Session::destroy ()
* callbacks from the engine any more.
*/
- Port::PortSignalDrop (); /* EMIT SIGNAL */
Port::PortDrop (); /* EMIT SIGNAL */
ltc_tx_cleanup();
@@ -1077,11 +1077,16 @@ Session::remove_monitor_section ()
}
remove_route (_monitor_out);
+ if (_state_of_the_state & Deletion) {
+ return;
+ }
+
auto_connect_master_bus ();
if (auditioner) {
auditioner->connect ();
}
+
Config->ParameterChanged ("use-monitor-bus");
}
@@ -3557,7 +3562,7 @@ Session::remove_routes (boost::shared_ptr<RouteList> routes_to_remove)
resort_routes ();
#endif
- if (_process_graph) {
+ if (_process_graph && !(_state_of_the_state & Deletion)) {
_process_graph->clear_other_chain ();
}
@@ -3574,6 +3579,10 @@ Session::remove_routes (boost::shared_ptr<RouteList> routes_to_remove)
(*iter)->drop_references ();
}
+ if (_state_of_the_state & Deletion) {
+ return;
+ }
+
Route::RemoteControlIDChange(); /* EMIT SIGNAL */
/* save the new state of the world */