summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/Common/ModuleManager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Common/ModuleManager.cpp b/src/Common/ModuleManager.cpp
index 738532f..25b0ee9 100644
--- a/src/Common/ModuleManager.cpp
+++ b/src/Common/ModuleManager.cpp
@@ -85,7 +85,8 @@ lt_dlhandle ModuleManager::loadModule(const std::string &name) {
mod = modules.insert(std::make_pair(lt_dlgetinfo(handle)->name, std::make_pair(handle, (Module*)0))).first;
}
if(!mod->second.second) {
- ModuleLoadFunc loader = (ModuleLoadFunc)lt_dlsym(mod->second.first, (name + "_create").c_str());
+ ModuleLoadFunc loader;
+ *(void**)&loader = lt_dlsym(mod->second.first, (name + "_create").c_str());
if(!loader)
return 0;