diff options
author | David Robillard <d@drobilla.net> | 2017-02-12 15:04:20 +0100 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2017-02-12 15:31:47 +0100 |
commit | b1198f0842e6e4d6b1c01f07d91b42ef4a212788 (patch) | |
tree | 93fdf4da89a6f5f634707fb8c989e0d9ee1a3c65 /src/server/BlockImpl.cpp | |
parent | 81d45973412c675e3c0b4a10b64d811a219feeae (diff) | |
download | ingen-b1198f0842e6e4d6b1c01f07d91b42ef4a212788.tar.gz ingen-b1198f0842e6e4d6b1c01f07d91b42ef4a212788.tar.bz2 ingen-b1198f0842e6e4d6b1c01f07d91b42ef4a212788.zip |
Use smart pointers to handle real-time memory disposal
Diffstat (limited to 'src/server/BlockImpl.cpp')
-rw-r--r-- | src/server/BlockImpl.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/server/BlockImpl.cpp b/src/server/BlockImpl.cpp index d3a5b02d..bdcf1500 100644 --- a/src/server/BlockImpl.cpp +++ b/src/server/BlockImpl.cpp @@ -40,7 +40,6 @@ BlockImpl::BlockImpl(PluginImpl* plugin, SampleRate srate) : NodeImpl(plugin->uris(), parent, symbol) , _plugin(plugin) - , _ports(NULL) , _polyphony((polyphonic && parent) ? parent->internal_poly() : 1) , _mark(Mark::UNVISITED) , _polyphonic(polyphonic) @@ -60,8 +59,6 @@ BlockImpl::~BlockImpl() if (is_linked()) { parent_graph()->remove_block(*this); } - - delete _ports; } Node* @@ -120,7 +117,7 @@ BlockImpl::prepare_poly(BufferFactory& bufs, uint32_t poly) } bool -BlockImpl::apply_poly(RunContext& context, Raul::Maid& maid, uint32_t poly) +BlockImpl::apply_poly(RunContext& context, uint32_t poly) { if (!_polyphonic) poly = 1; @@ -129,7 +126,7 @@ BlockImpl::apply_poly(RunContext& context, Raul::Maid& maid, uint32_t poly) if (_ports) for (uint32_t i = 0; i < num_ports(); ++i) - _ports->at(i)->apply_poly(context, maid, poly); + _ports->at(i)->apply_poly(context, poly); return true; } |