From a80fbe48abbe26adda3b0682c22c27b5652765db Mon Sep 17 00:00:00 2001 From: SimplestStudio Date: Tue, 24 Oct 2023 07:23:56 +0300 Subject: [PATCH] [win-linux] speed up application restart after update --- win-linux/extras/update-daemon/src/classes/csvcmanager.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/win-linux/extras/update-daemon/src/classes/csvcmanager.cpp b/win-linux/extras/update-daemon/src/classes/csvcmanager.cpp index 3a1fa9757..1ca369426 100644 --- a/win-linux/extras/update-daemon/src/classes/csvcmanager.cpp +++ b/win-linux/extras/update-daemon/src/classes/csvcmanager.cpp @@ -595,15 +595,15 @@ void CSvcManager::startReplacingFiles(const tstring &packageType, const bool res } } - // Remove Backup dir - NS_File::removeDirRecursively(tmpPath); - // Restart program if (restartAfterUpdate) { if (!NS_File::runProcess(appPath + APP_LAUNCH_NAME, _T(""))) NS_Logger::WriteLog(_T("An error occurred while restarting the program!"), true); } + // Remove Backup dir + NS_File::removeDirRecursively(tmpPath); + // Restart service #ifdef _WIN32 restartService();