summaryrefslogtreecommitdiff
path: root/libs/ardour/session.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/session.cc')
-rw-r--r--libs/ardour/session.cc18
1 files changed, 18 insertions, 0 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index 90e5809890..7f316c953a 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -2304,6 +2304,24 @@ Session::get_routes_with_internal_returns() const
return rl;
}
+bool
+Session::io_name_is_legal (const std::string& name)
+{
+ shared_ptr<RouteList> r = routes.reader ();
+
+ for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
+ if ((*i)->name() == name) {
+ return false;
+ }
+
+ if ((*i)->has_io_processor_named (name)) {
+ return false;
+ }
+ }
+
+ return true;
+}
+
shared_ptr<Route>
Session::route_by_name (string name)
{