summaryrefslogtreecommitdiffstats
path: root/src/engine/events
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2010-02-28 22:43:42 +0000
committerDavid Robillard <d@drobilla.net>2010-02-28 22:43:42 +0000
commitf127386923bfef5b3fb01a0f929a86585752b387 (patch)
tree625f26f6913069270a94ea5ac771a474556751e7 /src/engine/events
parentef3e95a930e0ac97cf12760150b93d18c6c0cbd8 (diff)
downloadingen-f127386923bfef5b3fb01a0f929a86585752b387.tar.gz
ingen-f127386923bfef5b3fb01a0f929a86585752b387.tar.bz2
ingen-f127386923bfef5b3fb01a0f929a86585752b387.zip
Fix loading LADSPA plugins from .om patches.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2509 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/engine/events')
-rw-r--r--src/engine/events/Connect.cpp3
-rw-r--r--src/engine/events/CreateNode.cpp21
2 files changed, 18 insertions, 6 deletions
diff --git a/src/engine/events/Connect.cpp b/src/engine/events/Connect.cpp
index 51378ca1..abc093a5 100644
--- a/src/engine/events/Connect.cpp
+++ b/src/engine/events/Connect.cpp
@@ -179,7 +179,8 @@ Connect::post_process()
return;
}
- ss << boost::format("Unable to make connection %1% -> %2% (") % _src_port_path % _dst_port_path;
+ ss << boost::format("Unable to make connection %1% -> %2% (")
+ % _src_port_path.chop_scheme() % _dst_port_path.chop_scheme();
switch (_error) {
case PARENT_PATCH_DIFFERENT:
diff --git a/src/engine/events/CreateNode.cpp b/src/engine/events/CreateNode.cpp
index 85d70305..dc3f4469 100644
--- a/src/engine/events/CreateNode.cpp
+++ b/src/engine/events/CreateNode.cpp
@@ -15,9 +15,9 @@
* 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#include "raul/log.hpp"
#include "raul/Maid.hpp"
#include "raul/Path.hpp"
-#include "raul/Path.hpp"
#include "redlandmm/World.hpp"
#include "shared/LV2URIMap.hpp"
#include "CreateNode.hpp"
@@ -62,12 +62,23 @@ CreateNode::CreateNode(
string uri = _plugin_uri.str();
if (uri.substr(0, 3) == "om:") {
size_t colon = 2;
+
uri = uri.substr(colon + 1);
- if ((colon = uri.find(":")) == string::npos)
+ if ((colon = uri.find(":")) == string::npos) {
+ Raul::error << "Invalid plugin URI `" << _plugin_uri << "'" << endl;
return;
- _plugin_type = uri.substr(0, colon + 1);
- _plugin_label = uri.substr(colon + 1);
- uri = "";
+ }
+ _plugin_type = uri.substr(0, colon);
+
+ uri = uri.substr(colon + 1);
+ if ((colon = uri.find(":")) == string::npos) {
+ Raul::error << "Invalid plugin URI `" << _plugin_uri << "'" << endl;
+ return;
+ }
+ _plugin_lib = uri.substr(0, colon);
+
+ uri = uri.substr(colon + 1);
+ _plugin_label = uri;
}
const LV2URIMap& uris = Shared::LV2URIMap::instance();