mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-12-16 04:09:39 +00:00
Merge pull request #13748 from Dentomologist/autoupdatechecker_delete_old_updater_log_file
AutoUpdateChecker: Delete old Updater.log file
This commit is contained in:
commit
9cc4d1b835
@ -79,9 +79,9 @@ std::string MakeUpdaterCommandLine(const std::map<std::string, std::string>& fla
|
|||||||
return cmdline;
|
return cmdline;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __APPLE__
|
|
||||||
void CleanupFromPreviousUpdate()
|
void CleanupFromPreviousUpdate()
|
||||||
{
|
{
|
||||||
|
#ifdef __APPLE__
|
||||||
// Remove the relocated updater file.
|
// Remove the relocated updater file.
|
||||||
File::DeleteDirRecursively(UpdaterPath(true));
|
File::DeleteDirRecursively(UpdaterPath(true));
|
||||||
|
|
||||||
@ -90,9 +90,12 @@ void CleanupFromPreviousUpdate()
|
|||||||
// version with an embedded updater, it won't delete the folder structure of the bundle, so
|
// version with an embedded updater, it won't delete the folder structure of the bundle, so
|
||||||
// we should clean those leftovers up.
|
// we should clean those leftovers up.
|
||||||
File::DeleteDirRecursively(File::GetExeDirectory() + DIR_SEP + "Dolphin Updater.app");
|
File::DeleteDirRecursively(File::GetExeDirectory() + DIR_SEP + "Dolphin Updater.app");
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Updater.log was moved from GetExeDirectory() to GetUserPath(D_LOGS_IDX) in 5.0-14529.
|
||||||
|
File::Delete(File::GetExeDirectory() + DIR_SEP + "Updater.log",
|
||||||
|
File::IfAbsentBehavior::NoConsoleWarning);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// This ignores i18n because most of the text in there (change descriptions) is only going to be
|
// This ignores i18n because most of the text in there (change descriptions) is only going to be
|
||||||
@ -190,7 +193,7 @@ void AutoUpdateChecker::CheckForUpdate(std::string_view update_track,
|
|||||||
if (!SystemSupportsAutoUpdates() || update_track.empty())
|
if (!SystemSupportsAutoUpdates() || update_track.empty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
#ifdef __APPLE__
|
#ifdef OS_SUPPORTS_UPDATER
|
||||||
CleanupFromPreviousUpdate();
|
CleanupFromPreviousUpdate();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user