From a6c1b3df28aabd7a4288e8783e2215c919b0c354 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Fri, 15 Apr 2016 19:07:25 +0000 Subject: correct path in update window git-svn-id: http://svn.miranda-ng.org/main/trunk@16667 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/PluginUpdater/src/DlgUpdate.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'plugins/PluginUpdater/src') diff --git a/plugins/PluginUpdater/src/DlgUpdate.cpp b/plugins/PluginUpdater/src/DlgUpdate.cpp index 542f5fd9b2..7f8728d96d 100644 --- a/plugins/PluginUpdater/src/DlgUpdate.cpp +++ b/plugins/PluginUpdater/src/DlgUpdate.cpp @@ -632,19 +632,19 @@ static int ScanFolder(const TCHAR *tszFolder, size_t cbBaseLen, const TCHAR *tsz if (CheckFileRename(ffd.cFileName, tszNewName)) Netlib_LogfT(hNetlibUser, _T("File %s will be renamed to %s."), ffd.cFileName, tszNewName); else { - if (level == 0) + if (level == 0) { // Rename Miranda*.exe - _tcsncpy_s(tszNewName, opts.bChangePlatform && !mir_tstrcmp(ffd.cFileName, OLD_FILENAME) ? NEW_FILENAME : ffd.cFileName, _TRUNCATE); - else + _tcsncpy_s(tszNewName, opts.bChangePlatform && !mir_tstrcmpi(ffd.cFileName, OLD_FILENAME) ? NEW_FILENAME : ffd.cFileName, _TRUNCATE); + mir_sntprintf(tszBuf, _T("%s\\%s"), tszFolder, tszNewName); + } + else { mir_sntprintf(tszNewName, _T("%s\\%s"), tszFolder + cbBaseLen, ffd.cFileName); + mir_sntprintf(tszBuf, _T("%s\\%s"), tszFolder, ffd.cFileName); + } } TCHAR *ptszUrl; int MyCRC; - if (opts.bChangePlatform) - mir_sntprintf(tszBuf, _T("%s\\%s"), tszFolder, tszNewName); - else - mir_sntprintf(tszBuf, _T("%s\\%s"), tszFolder, ffd.cFileName); bool bDeleteOnly = (tszNewName[0] == 0); // this file is not marked for deletion -- cgit v1.2.3