summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rwxr-xr-xinclude/module/ModuleLoader.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/module/ModuleLoader.hpp b/include/module/ModuleLoader.hpp
index a5416bb..d3b7d00 100755
--- a/include/module/ModuleLoader.hpp
+++ b/include/module/ModuleLoader.hpp
@@ -55,13 +55,13 @@ class BaseModuleLoader {
m.handle = LoadLibrary( it->c_str( ) );
#endif
if( !m.handle ) {
+ std::ostringstream ss;
#ifndef _WIN32
- throw std::runtime_error( dlerror( ) );
+ ss << "Module '" << *it << "' loading error: " << dlerror( );
#else
- std::ostringstream ss;
ss << "Module '" << *it << "' loading error: " << getLastError( );
- throw std::runtime_error( ss.str( ) );
#endif
+ throw std::runtime_error( ss.str( ) );
}
std::string registryName = "registry_" + demangle( typeid( Interface ) );