From 48a23e68b6eb6a23a4bd2e0a1fdfef339eaa7533 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 29 Jul 2008 16:58:35 +0000 Subject: Fix connecting via OSC. git-svn-id: http://svn.drobilla.net/lad/ingen@1304 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/Engine.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/libs') diff --git a/src/libs/engine/Engine.cpp b/src/libs/engine/Engine.cpp index 6b98566d..f0950844 100644 --- a/src/libs/engine/Engine.cpp +++ b/src/libs/engine/Engine.cpp @@ -166,11 +166,13 @@ Engine::start_jack_driver() void Engine::start_osc_driver(int port) { - if ( ! _event_source) - _event_source = SharedPtr(new OSCEngineReceiver( - *this, pre_processor_queue_size, port)); - else - cerr << "[Engine::start_osc_driver] Event source already running" << endl; + if (_event_source) { + cerr << "WARNING: Replacing event source" << endl; + _event_source.reset(); + } + + _event_source = SharedPtr(new OSCEngineReceiver( + *this, pre_processor_queue_size, port)); } -- cgit v1.2.1