diff options
author | David Robillard <d@drobilla.net> | 2011-02-04 05:48:37 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2011-02-04 05:48:37 +0000 |
commit | 77a78c6535a62bdadbf780a069aa47a4bfd01805 (patch) | |
tree | 1ef344a592e67a503b83ab92b82d34106283380d /src/plugininstance.c | |
parent | ea4087e0029c4f6c6f80716b50ddf60120598b1b (diff) | |
download | lilv-77a78c6535a62bdadbf780a069aa47a4bfd01805.tar.gz lilv-77a78c6535a62bdadbf780a069aa47a4bfd01805.tar.bz2 lilv-77a78c6535a62bdadbf780a069aa47a4bfd01805.zip |
Fix "ISO C forbids initialization between function pointer and ‘void *’" warnings.
Fix crash when plugins have no required or optional features.
git-svn-id: http://svn.drobilla.net/lad/trunk/slv2@2908 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/plugininstance.c')
-rw-r--r-- | src/plugininstance.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugininstance.c b/src/plugininstance.c index 9d1a2b8..ffe9b2b 100644 --- a/src/plugininstance.c +++ b/src/plugininstance.c @@ -22,7 +22,6 @@ #include <stdlib.h> #include <string.h> #include <assert.h> -#include <dlfcn.h> #include "slv2/plugin.h" #include "slv2/plugininstance.h" #include "slv2/types.h" @@ -30,6 +29,7 @@ #include "slv2/value.h" #include "slv2_internal.h" + SLV2Instance slv2_plugin_instantiate(SLV2Plugin plugin, double sample_rate, @@ -56,7 +56,8 @@ slv2_plugin_instantiate(SLV2Plugin plugin, return NULL; } - LV2_Descriptor_Function df = dlsym(lib, "lv2_descriptor"); + LV2_Descriptor_Function df = (LV2_Descriptor_Function) + slv2_dlfunc(lib, "lv2_descriptor"); if (!df) { SLV2_ERRORF("Could not find symbol 'lv2_descriptor', " |