diff options
author | David Robillard <d@drobilla.net> | 2009-10-21 02:10:24 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-10-21 02:10:24 +0000 |
commit | 20714a82da8b6c808be5f17d7add9e164ab154e3 (patch) | |
tree | 157c5f1b5c99be6c32064da059e5b9b6283ad50f /src/engine/LV2Node.cpp | |
parent | a0108c19c4704316a02c85676af349acdda29d72 (diff) | |
download | ingen-20714a82da8b6c808be5f17d7add9e164ab154e3.tar.gz ingen-20714a82da8b6c808be5f17d7add9e164ab154e3.tar.bz2 ingen-20714a82da8b6c808be5f17d7add9e164ab154e3.zip |
Fix crash when plugins fail to instantiate.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2199 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/engine/LV2Node.cpp')
-rw-r--r-- | src/engine/LV2Node.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/engine/LV2Node.cpp b/src/engine/LV2Node.cpp index 92f32b3c..df2ccbb2 100644 --- a/src/engine/LV2Node.cpp +++ b/src/engine/LV2Node.cpp @@ -60,8 +60,9 @@ LV2Node::LV2Node(LV2Plugin* plugin, LV2Node::~LV2Node() { - for (uint32_t i=0; i < _polyphony; ++i) - slv2_instance_free((*_instances)[i]); + if (_instances) + for (uint32_t i=0; i < _polyphony; ++i) + slv2_instance_free((*_instances)[i]); delete _instances; } |