diff --git a/src/lib/arch/unix/ArchPluginUnix.cpp b/src/lib/arch/unix/ArchPluginUnix.cpp index adf705da..f47f8079 100644 --- a/src/lib/arch/unix/ArchPluginUnix.cpp +++ b/src/lib/arch/unix/ArchPluginUnix.cpp @@ -64,7 +64,6 @@ ArchPluginUnix::load() while ((de = readdir(dir)) != NULL) { // ignore hidden files and diretories like .. and . if (de->d_name[0] != '.') { - LOG((CLOG_DEBUG "load plugin %s", de->d_name)); plugins.push_back(de->d_name); } } @@ -77,11 +76,13 @@ ArchPluginUnix::load() void* library = dlopen(path.c_str(), RTLD_LAZY); if (library == NULL) { + LOG((CLOG_ERR "failed to load plugin: %s", (*it).c_str())); throw XArch(dlerror()); } String filename = synergy::string::removeFileExt(*it); m_pluginTable.insert(std::make_pair(filename, library)); + LOG((CLOG_ERR "loaded plugin: %s", (*it).c_str())); } } diff --git a/src/lib/arch/win32/ArchPluginWindows.cpp b/src/lib/arch/win32/ArchPluginWindows.cpp index 7bbbe1a6..cb2abb90 100644 --- a/src/lib/arch/win32/ArchPluginWindows.cpp +++ b/src/lib/arch/win32/ArchPluginWindows.cpp @@ -56,16 +56,19 @@ ArchPluginWindows::load() std::vector::iterator it; for (it = plugins.begin(); it != plugins.end(); ++it) { LOG((CLOG_DEBUG "loading plugin: %s", (*it).c_str())); - String path = String(getPluginsDir()).append("\\").append(*it); + String path = String(dir).append("\\").append(*it); HINSTANCE library = LoadLibrary(path.c_str()); if (library == NULL) { + LOG((CLOG_ERR "failed to load plugin: %s %d", (*it).c_str(), GetLastError())); throw XArch(new XArchEvalWindows); } void* lib = reinterpret_cast(library); String filename = synergy::string::removeFileExt(*it); m_pluginTable.insert(std::make_pair(filename, lib)); + + LOG((CLOG_ERR "loaded plugin: %s", (*it).c_str())); } }