return;
}
- for (vector<boost::shared_ptr<Route> >::iterator x = routes.begin(); x != routes.end(); ++x) {
- _session->remove_route (*x);
+ {
+ Session::StateProtector sp (_session);
+ for (vector<boost::shared_ptr<Route> >::iterator x = routes.begin(); x != routes.end(); ++x) {
+ _session->remove_route (*x);
+ }
}
}
failed:
if (!new_routes.empty()) {
+ StateProtector sp (this);
add_routes (new_routes, true, true, true);
if (instrument) {
failed:
if (!new_routes.empty()) {
+ StateProtector sp (this);
add_routes (new_routes, true, true, true);
}
failure:
if (!ret.empty()) {
+ StateProtector sp (this);
add_routes (ret, false, true, true); // autoconnect outputs only
}
out:
if (!ret.empty()) {
+ StateProtector sp (this);
add_routes (ret, true, true, true);
IO::enable_connecting ();
}
SignalOrderRouteSorter sorter;
r.sort (sorter);
+ StateProtector sp (this);
+
for (RouteList::iterator i = r.begin(); i != r.end(); ++i) {
if (boost::dynamic_pointer_cast<Track> (*i)) {
(*i)->set_track_number(++tn);