1
0
mirror of https://github.com/veracrypt/VeraCrypt.git synced 2025-11-11 11:08:02 -06:00

macOS: Use correct Disk Utility location when "check filesystem" is ran (#1273)

This commit is contained in:
Jertzukka
2023-12-11 10:07:37 +02:00
committed by GitHub
parent ff93a6021f
commit 87a9508fdd

View File

@@ -107,7 +107,13 @@ namespace VeraCrypt
void CoreMacOSX::CheckFilesystem (shared_ptr <VolumeInfo> mountedVolume, bool repair) const
{
list <string> args;
args.push_back ("/Applications/Utilities/Disk Utility.app");
struct stat sb;
if (stat("/Applications/Utilities/Disk Utility.app", &sb) == 0)
args.push_back ("/Applications/Utilities/Disk Utility.app");
else
args.push_back ("/System/Applications/Utilities/Disk Utility.app");
Process::Execute ("open", args);
}