Changeset 274769 in webkit for trunk/Source/JavaScriptCore/shell
- Timestamp:
- Mar 22, 2021, 12:00:44 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/shell/DLLLauncherMain.cpp
r259565 r274769 83 83 } 84 84 85 static std::wstring iTunesDirectory() 86 { 87 return applePathFromRegistry(L"SOFTWARE\\Apple Computer, Inc.\\iTunes\\", L"InstallDir"); 88 } 89 85 90 static bool prependPath(const std::wstring& directoryToPrepend) 86 91 { … … 129 134 130 135 #else 131 132 const std::wstring& pathPrefix = appleApplicationSupportDirectory(); 133 134 if (!directoryExists(pathPrefix)) { 135 fatalError(programName, L"Failed to determine path to AAS directory."); 136 return false; 137 } 138 139 if (prependPath(pathPrefix)) 136 auto modifyPathWith = [&] (const std::wstring& pathPrefix) { 137 if (!prependPath(pathPrefix)) { 138 fatalError(programName, L"Failed to modify PATH environment variable."); 139 return false; 140 } 140 141 return true; 141 142 fatalError(programName, L"Failed to modify PATH environment variable."); 142 }; 143 144 const std::wstring& applicationSupportPathPrefix = appleApplicationSupportDirectory(); 145 if (directoryExists(applicationSupportPathPrefix)) 146 return modifyPathWith(applicationSupportPathPrefix); 147 148 const std::wstring& iTunesPathPrefix = iTunesDirectory(); 149 if (directoryExists(iTunesPathPrefix)) 150 return modifyPathWith(iTunesPathPrefix); 151 152 fatalError(programName, L"Couldn't find path to Apple Application Support (AAS) or iTunes via the registry. Do you have iTunes installed?"); 143 153 return false; 144 154 #endif
Note:
See TracChangeset
for help on using the changeset viewer.