aboutsummaryrefslogtreecommitdiff
path: root/backends/plugins
diff options
context:
space:
mode:
authorCeRiAl2011-05-20 06:20:52 +0800
committerIsmail Khatib2011-05-20 06:31:23 +0800
commite27dd8ac4ea487d388c59db53d7d7ee1ce24e9c9 (patch)
treeb97de19b8a04f6d6905efed670f19432c9369472 /backends/plugins
parentda3f6708984043322bd8e97535dd461977376417 (diff)
downloadscummvm-rg350-e27dd8ac4ea487d388c59db53d7d7ee1ce24e9c9.tar.gz
scummvm-rg350-e27dd8ac4ea487d388c59db53d7d7ee1ce24e9c9.tar.bz2
scummvm-rg350-e27dd8ac4ea487d388c59db53d7d7ee1ce24e9c9.zip
WINCE: Change plugin extensions from .dll to .plugin - fixes erroneous loading of runtime-dlls
Diffstat (limited to 'backends/plugins')
-rw-r--r--backends/plugins/win32/win32-provider.cpp20
1 files changed, 8 insertions, 12 deletions
diff --git a/backends/plugins/win32/win32-provider.cpp b/backends/plugins/win32/win32-provider.cpp
index bcbc6bde9e..0a08e48e6f 100644
--- a/backends/plugins/win32/win32-provider.cpp
+++ b/backends/plugins/win32/win32-provider.cpp
@@ -67,19 +67,11 @@ public:
bool loadPlugin() {
assert(!_dlHandle);
- #ifndef _WIN32_WCE
+#ifndef _WIN32_WCE
_dlHandle = LoadLibrary(_filename.c_str());
- #else
- if (!_filename.hasSuffix("scummvm.dll") &&
- !_filename.hasSuffix("libstdc++-6.dll") &&
- !_filename.hasSuffix("libgcc_s_sjlj-1.dll")) {
- // skip loading the core scummvm module and runtime dlls
- _dlHandle = LoadLibrary(toUnicode(_filename.c_str()));
- } else {
- // do not generate misleading error message
- return false;
- }
- #endif
+#else
+ _dlHandle = LoadLibrary(toUnicode(_filename.c_str()));
+#endif
if (!_dlHandle) {
debug("Failed loading plugin '%s' (error code %d)", _filename.c_str(), (int32) GetLastError());
@@ -111,7 +103,11 @@ Plugin* Win32PluginProvider::createPlugin(const Common::FSNode &node) const {
bool Win32PluginProvider::isPluginFilename(const Common::FSNode &node) const {
// Check the plugin suffix
Common::String filename = node.getName();
+#ifndef _WIN32_WCE
if (!filename.hasSuffix(".dll"))
+#else
+ if (!filename.hasSuffix(".plugin"))
+#endif
return false;
return true;