From c72e3f9fe11a3d6b72a04af599b04fde82091dd5 Mon Sep 17 00:00:00 2001 From: Tobias Weimer Date: Thu, 18 Sep 2014 19:32:43 +0000 Subject: PluginUpdater: - Show a notification when the update URL isn't available - small redesign of new components window - minor memory leaks fixecd git-svn-id: http://svn.miranda-ng.org/main/trunk@10509 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/PluginUpdater/src/unzipfile.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'plugins/PluginUpdater/src/unzipfile.cpp') diff --git a/plugins/PluginUpdater/src/unzipfile.cpp b/plugins/PluginUpdater/src/unzipfile.cpp index c0d0592e07..2b4ed8bf2f 100644 --- a/plugins/PluginUpdater/src/unzipfile.cpp +++ b/plugins/PluginUpdater/src/unzipfile.cpp @@ -39,12 +39,6 @@ static void PrepareFileName(TCHAR *dest, size_t destSize, const TCHAR *ptszPath, *p = '\\'; } -void BackupFile(TCHAR *ptszSrcFileName, TCHAR *ptszBackFileName) -{ - SafeCreateFilePath(ptszBackFileName); - SafeMoveFile(ptszSrcFileName, ptszBackFileName); -} - bool extractCurrentFile(unzFile uf, TCHAR *ptszDestPath, TCHAR *ptszBackPath, bool ch) { unz_file_info64 file_info; @@ -57,6 +51,8 @@ bool extractCurrentFile(unzFile uf, TCHAR *ptszDestPath, TCHAR *ptszBackPath, bo for (char *p = strchr(filename, '/'); p; p = strchr(p+1, '/')) *p = '\\'; + // This is because there may be more then one file in a single zip + // So we need to check each file if (ch && !db_get_b(NULL, MODNAME "Files", StrToLower(ptrA(mir_strdup(filename))), 1)) return true; -- cgit v1.2.3