Wipe clean VSH's temporary directory of choice at boot

This commit is contained in:
Eladash 2022-01-07 19:16:03 +02:00 committed by Ivan
parent 285322982f
commit 1088375b38
7 changed files with 15 additions and 6 deletions

View file

@ -1788,7 +1788,7 @@ const std::string& fs::get_temp_dir()
return s_dir;
}
bool fs::remove_all(const std::string& path, bool remove_root)
bool fs::remove_all(const std::string& path, bool remove_root, bool is_no_dir_ok)
{
if (const auto root_dir = dir(path))
{
@ -1817,7 +1817,7 @@ bool fs::remove_all(const std::string& path, bool remove_root)
}
else
{
return false;
return is_no_dir_ok;
}
if (remove_root)