From: sirakaba Date: Mon, 30 Jul 2012 10:47:40 +0000 (+0000) Subject: 書庫を作成する際にTPI内部のエンジンが存在するかどうかを確認していなかったバグを修正。 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=54e82e87286d4d254f7669a4a39c0e652aa3dec1;p=tpi%2Flychee.git 書庫を作成する際にTPI内部のエンジンが存在するかどうかを確認していなかったバグを修正。 git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/tpi/tpi@621 9df91469-1e22-0410-86e7-ea8537beb833 --- diff --git a/doc/history.html b/doc/history.html index 100a922..555764b 100644 --- a/doc/history.html +++ b/doc/history.html @@ -29,12 +29,13 @@

History

-

Ver.0.01β15 (2012/05/--)

+

Ver.0.01β15 (2012/08/--)

Lychee
  • Linux版、Windows版とも32bit版と64bit版の双方を同封するよう変更。
  • +
  • 書庫を作成する際にTPI内部のエンジンが存在するかどうかを確認していなかったバグを修正。
diff --git a/src/common/handle/TPIHandle.cpp b/src/common/handle/TPIHandle.cpp index 7e3baf5..db087a8 100644 --- a/src/common/handle/TPIHandle.cpp +++ b/src/common/handle/TPIHandle.cpp @@ -60,11 +60,6 @@ bool TPIHandle::InitLibrary(const wxString & _szLibName, const wxString & _szArc return false; } - if (_szArcName.IsEmpty()) - { - return true; - } - GetAPIAddress("LoadPlugin", p); int nErrorCode = ((int (__stdcall *)(const wxString &, TPI_PROC, wxULongLong_t)) p)(_szArcName, _prProc, _llTypeId); if (! this->GetPluginInformation(TPI_INFO_HANDLE_ON_COMMAND, 0, & this->bHandleOnCommand)) diff --git a/src/plugin/calLibrary/calLibrary.cpp b/src/plugin/calLibrary/calLibrary.cpp index f6a90c5..e593efd 100644 --- a/src/plugin/calLibrary/calLibrary.cpp +++ b/src/plugin/calLibrary/calLibrary.cpp @@ -602,7 +602,12 @@ int __stdcall LoadPlugin // 対象が存在するならば対応するライブラリを調査、 // 対象が存在しないならば指示されたライブラリをロード。 + // 対象が空文字列なら処理を終了。 ::RemoveCwdFromSearchPath(); + if (_szArcName.IsEmpty()) + { + return TPI_ERROR_SUCCESS; + } if (! ::wxFileExists(_szArcName)) { xmlLibrary = myGetFirstLib(& xmlDoc, _nTypeId); diff --git a/src/plugin/cuiWrapper/cuiWrapper.cpp b/src/plugin/cuiWrapper/cuiWrapper.cpp index 1ee4032..1a91d23 100644 --- a/src/plugin/cuiWrapper/cuiWrapper.cpp +++ b/src/plugin/cuiWrapper/cuiWrapper.cpp @@ -241,6 +241,11 @@ int __stdcall LoadPlugin // 対象が存在するならば対応するライブラリを調査、 // 対象が存在しないならば指示されたライブラリをロード。 + // 対象が空文字列なら処理を終了。 + if (_szArcName.IsEmpty()) + { + return TPI_ERROR_SUCCESS; + } if (! ::wxFileExists(_szArcName)) { xmlLibrary = myGetFirstLib(& xmlDoc, _nTypeId); diff --git a/src/plugin/spiLibrary/spiLibrary.cpp b/src/plugin/spiLibrary/spiLibrary.cpp index efcd6f0..c88a2a5 100644 --- a/src/plugin/spiLibrary/spiLibrary.cpp +++ b/src/plugin/spiLibrary/spiLibrary.cpp @@ -123,6 +123,13 @@ int __stdcall LoadPlugin wxULongLong_t ) { + // 対象が空文字列なら処理を終了。 + ::RemoveCwdFromSearchPath(); + if (_szArcName.IsEmpty()) + { + return TPI_ERROR_SUCCESS; + } + // ファイルを開く。 char buffer[2050]; { diff --git a/src/plugin/xpiLibrary/xpiLibrary.cpp b/src/plugin/xpiLibrary/xpiLibrary.cpp index 3fde702..9297e11 100644 --- a/src/plugin/xpiLibrary/xpiLibrary.cpp +++ b/src/plugin/xpiLibrary/xpiLibrary.cpp @@ -128,6 +128,13 @@ int __stdcall LoadPlugin wxULongLong_t ) { + // 対象が空文字列なら処理を終了。 + ::RemoveCwdFromSearchPath(); + if (_szArcName.IsEmpty()) + { + return TPI_ERROR_SUCCESS; + } + // ファイルを開く。 char buffer[2050]; {