summaryrefslogtreecommitdiff
path: root/plugins/PluginUpdater/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-09-01 15:17:39 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-09-01 15:17:39 +0000
commit1b9f36054bddeef87d4f9c139877d28c4e6b1702 (patch)
treed462cc03209954cf5d3c1172300c7645c0d19c3c /plugins/PluginUpdater/src
parent039db3b302a3f7a3e78f89e430c8cb83efb12b5e (diff)
- strdel()/strdelw() moved to the core;
- custom implementations removed git-svn-id: http://svn.miranda-ng.org/main/trunk@15135 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/PluginUpdater/src')
-rw-r--r--plugins/PluginUpdater/src/Compat/compat.h8
-rw-r--r--plugins/PluginUpdater/src/DlgUpdate.cpp4
-rw-r--r--plugins/PluginUpdater/src/Utils.cpp9
-rw-r--r--plugins/PluginUpdater/src/stdafx.h1
4 files changed, 10 insertions, 12 deletions
diff --git a/plugins/PluginUpdater/src/Compat/compat.h b/plugins/PluginUpdater/src/Compat/compat.h
index 5818adcef1..4c0d0849eb 100644
--- a/plugins/PluginUpdater/src/Compat/compat.h
+++ b/plugins/PluginUpdater/src/Compat/compat.h
@@ -155,5 +155,13 @@ __forceinline TCHAR *Utils_ReplaceVarsT(const TCHAR *szData, MCONTACT hContact,
return (TCHAR*)CallService(MS_UTILS_REPLACEVARS, (WPARAM)szData, (LPARAM)&vars);
}
+void strdelt(TCHAR *parBuffer, int len)
+{
+ TCHAR* p;
+ for (p = parBuffer + len; *p != 0; p++)
+ p[-len] = *p;
+
+ p[-len] = '\0';
+}
#define _qtoupper(_c) (((_c) >= 'a' && (_c) <= 'z')?((_c)-('a'+'A')):(_c))
diff --git a/plugins/PluginUpdater/src/DlgUpdate.cpp b/plugins/PluginUpdater/src/DlgUpdate.cpp
index b3298611f1..cba35cebe7 100644
--- a/plugins/PluginUpdater/src/DlgUpdate.cpp
+++ b/plugins/PluginUpdater/src/DlgUpdate.cpp
@@ -646,13 +646,13 @@ static int ScanFolder(const TCHAR *tszFolder, size_t cbBaseLen, int level, const
// remove trailing w or W and try again
int iPos = int(p - tszNewName) - 1;
- strdel(p - 1, 1);
+ strdelt(p - 1, 1);
if ((item = hashes.find((ServListEntry*)&pName)) == NULL) {
Netlib_LogfT(hNetlibUser, _T("File %s: Not found on server, skipping"), ffd.cFileName);
continue;
}
- strdel(tszNewName + iPos, 1);
+ strdelt(tszNewName + iPos, 1);
}
#if MIRANDA_VER >= 0x0A00
diff --git a/plugins/PluginUpdater/src/Utils.cpp b/plugins/PluginUpdater/src/Utils.cpp
index 30f212abe1..47e73a0e53 100644
--- a/plugins/PluginUpdater/src/Utils.cpp
+++ b/plugins/PluginUpdater/src/Utils.cpp
@@ -313,15 +313,6 @@ bool DownloadFile(FILEURL *pFileURL, HANDLE &nlc)
return ret;
}
-void strdel(TCHAR *parBuffer, int len)
-{
- TCHAR* p;
- for (p = parBuffer + len; *p != 0; p++)
- p[-len] = *p;
-
- p[-len] = '\0';
-}
-
void __stdcall OpenPluginOptions(void*)
{
OPENOPTIONSDIALOG ood = {0};
diff --git a/plugins/PluginUpdater/src/stdafx.h b/plugins/PluginUpdater/src/stdafx.h
index 146c1ac49c..5491dd325b 100644
--- a/plugins/PluginUpdater/src/stdafx.h
+++ b/plugins/PluginUpdater/src/stdafx.h
@@ -226,7 +226,6 @@ void CheckUpdateOnStartup();
void InitTimer(void *type);
bool unzip(const TCHAR *ptszZipFile, TCHAR *ptszDestPath, TCHAR *ptszBackPath,bool ch);
-void strdel(TCHAR *parBuffer, int len);
///////////////////////////////////////////////////////////////////////////////