summaryrefslogtreecommitdiff
path: root/libs/ardour/plugin_insert.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2020-02-13 00:47:18 +0100
committerRobin Gareus <robin@gareus.org>2020-02-13 00:47:18 +0100
commit46a6f47362d56955c3f5cca2943029f042df1e7c (patch)
treeace7157bc0ba99f268195b589c1d04b2314cf0dd /libs/ardour/plugin_insert.cc
parent260e7ad5a9349f1e73b168f5ca71da0f9a54ecdc (diff)
Address sidechain-port name uniqueness
[Re]name sidechain port directly when a plugin is added. Usually plugins are constructed without an Route (owner is unset). PluginInsert c'tor may already create a side-chain port, at the time of construction the sidechain port will be created using the port-name "toBeRenamed". Previously the plugin had to be added to a route using "add_processor", in order to set a unique name, before a new plugin with sidechain could be constructed. ProcessorBox::use_plugins() did that in the correct sequence, however there may have been cases where this didn't work, and Route::add_processors() was called directly..
Diffstat (limited to 'libs/ardour/plugin_insert.cc')
-rw-r--r--libs/ardour/plugin_insert.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/ardour/plugin_insert.cc b/libs/ardour/plugin_insert.cc
index 22e40e4b63..4c4d7e875f 100644
--- a/libs/ardour/plugin_insert.cc
+++ b/libs/ardour/plugin_insert.cc
@@ -222,7 +222,7 @@ PluginInsert::add_sidechain (uint32_t n_audio, uint32_t n_midi)
} else if (owner()) {
n << "SC " << owner()->name() << "/" << name() << " " << Session::next_name_id ();
} else {
- n << "tobeRenamed";
+ n << "toBeRenamed" << id().to_s();
}
SideChain *sc = new SideChain (_session, n.str ());
_sidechain = boost::shared_ptr<SideChain> (sc);