@@ -1501,9 +1501,6 @@ class PythonBootstrapperApplication : public CBalBaseBootstrapperApplication {
1501
1501
hr = UpdateUIStrings (_command.action );
1502
1502
BalExitOnFailure (hr, " Failed to load UI strings." );
1503
1503
1504
- hr = FindProgramFilesArm ();
1505
- BalExitOnFailure (hr, " Fatal error locating Program Files (Arm)" );
1506
-
1507
1504
GetBundleFileVersion ();
1508
1505
// don't fail if we couldn't get the version info; best-effort only
1509
1506
LExit:
@@ -2184,37 +2181,6 @@ class PythonBootstrapperApplication : public CBalBaseBootstrapperApplication {
2184
2181
return hr;
2185
2182
}
2186
2183
2187
- HRESULT FindProgramFilesArm () {
2188
- wchar_t buffer[MAX_PATH + 1 ];
2189
- DWORD bufferLen = MAX_PATH;
2190
- LSTATUS res = RegGetValueW (
2191
- HKEY_LOCAL_MACHINE,
2192
- L" SOFTWARE\\ Microsoft\\ Windows\\ CurrentVersion" ,
2193
- L" ProgramFilesDir (Arm)" ,
2194
- RRF_RT_REG_SZ | RRF_RT_REG_EXPAND_SZ | RRF_SUBKEY_WOW6464KEY,
2195
- NULL ,
2196
- buffer,
2197
- &bufferLen
2198
- );
2199
- if (res != ERROR_SUCCESS) {
2200
- // ProgramFilesArmFolder will default to ProgramFilesFolder. We only report
2201
- // an error if the value existed, as it will simply just be absent on non-ARM
2202
- // devices.
2203
- if (res != ERROR_FILE_NOT_FOUND) {
2204
- BalLog (BOOTSTRAPPER_LOG_LEVEL_ERROR, " Failed to query 'ProgramFilesDir (Arm)': error code %d" , res);
2205
- }
2206
- return S_OK;
2207
- }
2208
- if (buffer[0 ]) {
2209
- wchar_t *p = &buffer[bufferLen / sizeof (wchar_t ) - 1 ];
2210
- while (*p == L' \\ ' || *p == L' \0 ' ) { p -= 1 ; }
2211
- *++p = L' \\ ' ;
2212
- *++p = L' \0 ' ;
2213
- _engine->SetVariableString (L" ProgramFilesArmFolder" , buffer);
2214
- }
2215
- return S_OK;
2216
- }
2217
-
2218
2184
//
2219
2185
// OnPlan - plan the detected changes.
2220
2186
//
0 commit comments