aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanspeter Portner <dev@open-music-kontrollers.ch>2017-05-22 10:07:55 +0200
committerHanspeter Portner <dev@open-music-kontrollers.ch>2017-05-22 10:07:55 +0200
commit20e0d4a6037ddbc51ed7e396caa669cfbe75c691 (patch)
treea970e95f9e7fcbf3cbed339045700d45c41f32ab
parente6ced6bca1ef670b434835c36cde7321b1411972 (diff)
downloadsynthpod-20e0d4a6037ddbc51ed7e396caa669cfbe75c691.tar.xz
nk: prevent double initialization of mod.
-rw-r--r--VERSION2
-rw-r--r--plugins/synthpod_common_nk.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/VERSION b/VERSION
index 8d4951a6..d9005188 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.1.4983
+0.1.4985
diff --git a/plugins/synthpod_common_nk.c b/plugins/synthpod_common_nk.c
index 0f8fa4ef..29e3c5c7 100644
--- a/plugins/synthpod_common_nk.c
+++ b/plugins/synthpod_common_nk.c
@@ -2340,6 +2340,9 @@ _mod_add(plughandle_t *handle, LV2_URID urn)
static void
_mod_init(plughandle_t *handle, mod_t *mod, const LilvPlugin *plug)
{
+ if(mod->plug) // already initialized
+ return;
+
mod->plug = plug;
const unsigned num_ports = lilv_plugin_get_num_ports(plug) + 1; // + automation port