Salome HOME
Merge remote branch 'origin/V8_5_asterstudy'
[modules/smesh.git] / src / SMESH_I / SMESH_Gen_i.cxx
index f994b82f0762ac67efd7c632710618cb0685a379..75c9d2184ece2e5cde5aec19f65771cdbe4fd314 100644 (file)
@@ -439,7 +439,19 @@ GenericHypothesisCreator_i* SMESH_Gen_i::getHypothesisCreator(const char* theHyp
     {
       // load plugin library
       if(MYDEBUG) MESSAGE("Loading server meshers plugin library ...");
-      LibHandle libHandle = LoadLib( aPlatformLibName.c_str() );
+#ifdef WIN32
+  #ifdef UNICODE
+         const wchar_t* path = Kernel_Utils::decode_s(aPlatformLibName);
+  #else
+         const char* path = aPlatformLibName.c_str();
+  #endif
+#else
+         const char* path = aPlatformLibName.c_str();
+#endif
+      LibHandle libHandle = LoadLib( path );
+#if defined(WIN32) && defined(UNICODE)
+         delete path;
+#endif
       if (!libHandle)
       {
         // report any error, if occurred