diff --git a/source/glest_game/main/main.cpp b/source/glest_game/main/main.cpp index 27bb5530..82118f11 100644 --- a/source/glest_game/main/main.cpp +++ b/source/glest_game/main/main.cpp @@ -4439,6 +4439,10 @@ int glestMain(int argc, char** argv) { } createDirectoryPaths(tempDataPath); + string binaryNameOld = Properties::getApplicationPath() + extractFileFromDirectoryPath(PlatformExceptionHandler::application_binary) + "__REMOVE"; + if(fileExists(binaryNameOld)) { + removeFile(binaryNameOld); + } if(hasCommandArgument(argc, argv,GAME_ARGS[GAME_ARG_USE_PORTS]) == true) { int foundParamIndIndex = -1; diff --git a/source/glest_game/menu/menu_state_root.cpp b/source/glest_game/menu/menu_state_root.cpp index d4a248b7..edfd7b6c 100644 --- a/source/glest_game/menu/menu_state_root.cpp +++ b/source/glest_game/menu/menu_state_root.cpp @@ -460,7 +460,7 @@ void MenuStateRoot::FTPClient_CallbackEvent(string itemName, resultRename = renameFile(binaryNameOld, binaryName); //if(SystemFlags::VERBOSE_MODE_ENABLED) printf("Rename: [%s] to [%s] result = %d\n",binaryName.c_str(),binaryNameOld.c_str(),resultRename); - printf("#2 Rename: [%s] to [%s] result = %d errno = %d\n",binaryName.c_str(),binaryNameOld.c_str(),resultRename, errno); + printf("#2 Rename: [%s] to [%s] result = %d errno = %d\n",binaryNameOld.c_str(),binaryName.c_str(),resultRename, errno); } console.addLine("Successfully updated, please restart!",true);