summaryrefslogtreecommitdiff
path: root/updater/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'updater/main.cpp')
-rw-r--r--updater/main.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/updater/main.cpp b/updater/main.cpp
index a345d58..ac39264 100644
--- a/updater/main.cpp
+++ b/updater/main.cpp
@@ -57,13 +57,14 @@ int main(int argc, char* argv[])
Logger::Warn("Client executable is absent\n");
}
- if (QFile::rename(dir + PathSlash + "client.bin.latest", dir + PathSlash + ClientName))
+ // copy client.bin.lates to client.exe or client
+ if (QFile::copy(dir + PathSlash + "client.bin.latest", dir + PathSlash + ClientName))
{
Logger::Info("Client successfully updated\n");
}
else
{
- Logger::Fatal("Can't rename 'client.bin.latest'\n");
+ Logger::Fatal("Can't copy 'client.bin.latest'\n");
return -1;
}