OSDN Git Service

XPIを常に絶対パスで呼び出すよう変更。
authorsirakaba <sirakaba@9df91469-1e22-0410-86e7-ea8537beb833>
Sun, 29 Aug 2010 04:26:16 +0000 (04:26 +0000)
committersirakaba <sirakaba@9df91469-1e22-0410-86e7-ea8537beb833>
Sun, 29 Aug 2010 04:26:16 +0000 (04:26 +0000)
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/tpi/tpi@294 9df91469-1e22-0410-86e7-ea8537beb833

src/plugin/xpiLibrary/xpiLibrary.cpp

index 338e62e..e564401 100644 (file)
@@ -404,10 +404,16 @@ int __stdcall Command
                return nErrorCode;\r
        }\r
 \r
+       wxString szXPIPath;\r
+       {\r
+               wxStandardPaths p;\r
+               szXPIPath = wxPathOnly(p.GetExecutablePath()) + wxT("/lib/");\r
+       }\r
+\r
        for (size_t i = 0; i < _asFiles.GetCount(); i++)\r
        {\r
                // XPIをロード。\r
-               HMODULE hXPI = ::LoadLibrary(wxFileName(_asFiles[i]).GetPath().wchar_str());\r
+               HMODULE hXPI = ::LoadLibrary((szXPIPath + wxFileName(_asFiles[i]).GetPath()).wchar_str());\r
                if (hXPI == NULL)\r
                {\r
                        nErrorCode = TPI_ERROR_U_USE_LIBRARY;\r