From 4b1832ba51f1b6b722810a1fa83333ace84152da Mon Sep 17 00:00:00 2001 From: David Robillard Date: Mon, 17 Nov 2014 06:44:49 +0000 Subject: Fix a few minor/unlikely memory errors. git-svn-id: http://svn.drobilla.net/lad/trunk/suil@5485 a436a847-0d15-0410-975c-d299462d15a1 --- src/instance.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/instance.c b/src/instance.c index 06d6287..e5cf54d 100644 --- a/src/instance.c +++ b/src/instance.c @@ -114,6 +114,7 @@ open_wrapper(SuilHost* host, void* lib = dlopen(path, RTLD_NOW); if (!lib) { SUIL_ERRORF("Unable to open wrap module %s (%s)\n", path, dlerror()); + free(path); return NULL; } @@ -203,7 +204,7 @@ suil_instance_new(SuilHost* host, instance->descriptor = descriptor; // Make UI features array - instance->features = (LV2_Feature**)malloc(sizeof(LV2_Feature**)); + instance->features = (LV2_Feature**)malloc(sizeof(LV2_Feature*)); instance->features[0] = NULL; // Copy user provided features -- cgit v1.2.1