diff --git a/CHANGELOG.md b/CHANGELOG.md index e38478d8..6da545cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,7 +16,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). - fixed delete v1/v2 display now respects global presets - Avoid blocking the Explorer when dragging [#2660](https://github.com/sandboxie-plus/Sandboxie/pull/2660) - fixed issue with QtSingleApp [#2659](https://github.com/sandboxie-plus/Sandboxie/issues/2659) - +- fixed updater sometimes failing to create temp dir [#2615](https://github.com/sandboxie-plus/Sandboxie/issues/2615) diff --git a/SandboxiePlus/SandMan/OnlineUpdater.cpp b/SandboxiePlus/SandMan/OnlineUpdater.cpp index 87c9fb80..c379ce38 100644 --- a/SandboxiePlus/SandMan/OnlineUpdater.cpp +++ b/SandboxiePlus/SandMan/OnlineUpdater.cpp @@ -63,7 +63,7 @@ COnlineUpdater::COnlineUpdater(QObject *parent) : QObject(parent) bool bCanRunInstaller = OnNewRelease == "install"; bool bIsUpdateReady = false; - QVariantMap Update = QJsonDocument::fromJson(ReadFileAsString(GetUpdateDir(true) + "/" UPDATE_FILE).toUtf8()).toVariant().toMap(); + QVariantMap Update = QJsonDocument::fromJson(ReadFileAsString(GetUpdateDir() + "/" UPDATE_FILE).toUtf8()).toVariant().toMap(); if (!Update.isEmpty()) { int iUpdate = 0; QString UpdateStr = ParseVersionStr(theConf->GetString("Updater/UpdateVersion"), &iUpdate); @@ -352,7 +352,7 @@ bool COnlineUpdater::HandleUpdate() { bool bIsUpdateReady = false; if (theConf->GetString("Updater/UpdateVersion") == MakeVersionStr(Update)) - bIsUpdateReady = QFile::exists(GetUpdateDir(true) + "/" UPDATE_FILE); + bIsUpdateReady = QFile::exists(GetUpdateDir() + "/" UPDATE_FILE); if (!bIsUpdateReady) { @@ -610,7 +610,7 @@ bool COnlineUpdater::ApplyUpdate(bool bSilent) return false; } - QVariantMap Update = QJsonDocument::fromJson(ReadFileAsString(GetUpdateDir(true) + "/" UPDATE_FILE).toUtf8()).toVariant().toMap(); + QVariantMap Update = QJsonDocument::fromJson(ReadFileAsString(GetUpdateDir() + "/" UPDATE_FILE).toUtf8()).toVariant().toMap(); EUpdateScope Scope = ScanUpdateFiles(Update); if (Scope == eNone) return true; // nothing to do @@ -725,7 +725,7 @@ void COnlineUpdater::OnInstallerDownload() if (Name.isEmpty() || Name.right(4).compare(".exe", Qt::CaseInsensitive) != 0) Name = "Sandboxie-Plus-Install.exe"; - QString FilePath = GetUpdateDir() + "/" + Name; + QString FilePath = GetUpdateDir(true) + "/" + Name; QFile File(FilePath); if (File.open(QFile::WriteOnly)) {