diff options
author | Robin Gareus <robin@gareus.org> | 2017-04-12 17:37:26 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2017-04-12 17:37:26 +0200 |
commit | 64f40c09fab28c91892058845c004d12c84636fe (patch) | |
tree | c63d9d3c9047782a9cd69601a4f3dc5576927306 /libs/ardour | |
parent | 85c587d7025edbd33ae6e8bbcf06b6e5a2c66bdd (diff) |
Fix setting Plugin-Owner (route) for analysis plugins
Diffstat (limited to 'libs/ardour')
-rw-r--r-- | libs/ardour/luaproc.cc | 3 | ||||
-rw-r--r-- | libs/ardour/plugin.cc | 2 | ||||
-rw-r--r-- | libs/ardour/plugin_insert.cc | 1 |
3 files changed, 6 insertions, 0 deletions
diff --git a/libs/ardour/luaproc.cc b/libs/ardour/luaproc.cc index bae1bd6d3d..5b829a742b 100644 --- a/libs/ardour/luaproc.cc +++ b/libs/ardour/luaproc.cc @@ -174,6 +174,9 @@ LuaProc::init () boost::weak_ptr<Route> LuaProc::route () const { + if (!_owner) { + return boost::weak_ptr<Route>(); + } return static_cast<Route*>(_owner)->weakroute (); } diff --git a/libs/ardour/plugin.cc b/libs/ardour/plugin.cc index 8051e95804..7c96922571 100644 --- a/libs/ardour/plugin.cc +++ b/libs/ardour/plugin.cc @@ -97,6 +97,7 @@ Plugin::Plugin (AudioEngine& e, Session& s) : _engine (e) , _session (s) , _cycles (0) + , _owner (0) , _have_presets (false) , _have_pending_stop_events (false) , _parameter_changed_since_last_preset (false) @@ -111,6 +112,7 @@ Plugin::Plugin (const Plugin& other) , _session (other._session) , _info (other._info) , _cycles (0) + , _owner (other._owner) , _have_presets (false) , _have_pending_stop_events (false) , _parameter_changed_since_last_preset (false) diff --git a/libs/ardour/plugin_insert.cc b/libs/ardour/plugin_insert.cc index 25b0e7e46a..7196a6d844 100644 --- a/libs/ardour/plugin_insert.cc +++ b/libs/ardour/plugin_insert.cc @@ -2978,6 +2978,7 @@ PluginInsert::get_impulse_analysis_plugin() assert (out == internal_output_streams ()); } ret->configure_io (internal_input_streams (), out); + ret->set_owner (_owner); _impulseAnalysisPlugin = ret; } else { ret = _impulseAnalysisPlugin.lock(); |