diff options
author | David Robillard <d@drobilla.net> | 2009-10-31 23:31:49 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-10-31 23:31:49 +0000 |
commit | 2ba6b399610313d4ad09ada73e271f743763bea3 (patch) | |
tree | bf23bb4e63e9420a21a5984d9a26ea91474dec3d /src/engine | |
parent | 1a77cedde712ca7b8f0e68246877747b0be07bd9 (diff) | |
download | ingen-2ba6b399610313d4ad09ada73e271f743763bea3.tar.gz ingen-2ba6b399610313d4ad09ada73e271f743763bea3.tar.bz2 ingen-2ba6b399610313d4ad09ada73e271f743763bea3.zip |
Don't double-send creation events when they are a result of a PUT.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2205 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/engine')
-rw-r--r-- | src/engine/events/CreateNode.cpp | 3 | ||||
-rw-r--r-- | src/engine/events/CreatePort.cpp | 3 | ||||
-rw-r--r-- | src/engine/events/SetMetadata.cpp | 6 |
3 files changed, 9 insertions, 3 deletions
diff --git a/src/engine/events/CreateNode.cpp b/src/engine/events/CreateNode.cpp index 966f96c1..6c70d481 100644 --- a/src/engine/events/CreateNode.cpp +++ b/src/engine/events/CreateNode.cpp @@ -128,6 +128,9 @@ CreateNode::execute(ProcessContext& context) void CreateNode::post_process() { + if (!_responder) + return; + string msg; if (_node_already_exists) { msg = string("Could not create node - ").append(_path.str());// + " already exists."; diff --git a/src/engine/events/CreatePort.cpp b/src/engine/events/CreatePort.cpp index ba4fd9fe..5ea78fb0 100644 --- a/src/engine/events/CreatePort.cpp +++ b/src/engine/events/CreatePort.cpp @@ -163,6 +163,9 @@ CreatePort::execute(ProcessContext& context) void CreatePort::post_process() { + if (!_responder) + return; + string msg; switch (_error) { case NO_ERROR: diff --git a/src/engine/events/SetMetadata.cpp b/src/engine/events/SetMetadata.cpp index 3d62781d..a642ba18 100644 --- a/src/engine/events/SetMetadata.cpp +++ b/src/engine/events/SetMetadata.cpp @@ -101,15 +101,15 @@ SetMetadata::pre_process() iterator p = _properties.find("ingen:polyphony"); if (p != _properties.end() && p->second.is_valid() && p->second.type() == Atom::INT) poly = p->second.get_int32(); - _create_event = new CreatePatch(_engine, _responder, _time, + _create_event = new CreatePatch(_engine, SharedPtr<Responder>(), _time, path, poly, _properties); } else if (is_node) { const iterator p = _properties.find("rdf:instanceOf"); - _create_event = new CreateNode(_engine, _responder, _time, + _create_event = new CreateNode(_engine, SharedPtr<Responder>(), _time, path, p->second.get_uri(), true, _properties); } else if (is_port) { _blocking = true; - _create_event = new CreatePort(_engine, _responder, _time, + _create_event = new CreatePort(_engine, SharedPtr<Responder>(), _time, path, data_type.uri(), is_output, _source, _properties); } if (_create_event) |