Bug 1424670 - Don't hard code a Program Files path. r?agashlin draft
authorMatt Howell <mhowell@mozilla.com>
Sun, 10 Dec 2017 19:11:10 -0800
changeset 710618 4a748d91cc03d0869f8b9f8afe33968929efb4e7
parent 710528 52fbf40d3e7d0ee443fe8ee3c0d360c2ce87d2ce
child 743611 3ce0fbe27f1f2933d8c84b3250f982a489194580
push id92857
push userbmo:mhowell@mozilla.com
push dateMon, 11 Dec 2017 03:14:33 +0000
reviewersagashlin
bugs1424670
milestone59.0a1
Bug 1424670 - Don't hard code a Program Files path. r?agashlin MozReview-Commit-ID: 6mTwiyvvrVk
browser/installer/windows/nsis/stub.nsi
--- a/browser/installer/windows/nsis/stub.nsi
+++ b/browser/installer/windows/nsis/stub.nsi
@@ -1883,21 +1883,21 @@ Function ShouldInstall64Bit
   System::Call "*$1(i, i, l.r2, l, l, l, l, l, l)"
   System::Free $1
   ${If} $2 L<= ${RAM_NEEDED_FOR_64BIT}
     Return
   ${EndIf}
 
   ; Lenovo OneKey Theater can theoretically be in a directory other than this
   ; one, because some installer versions let you change it, but it's unlikely.
-  ${If} ${FileExists} "C:\Program Files (x86)\Lenovo\Onekey Theater\windowsapihookdll64.dll"
+  ${If} ${FileExists} "$PROGRAMFILES32\Lenovo\Onekey Theater\windowsapihookdll64.dll"
     Return
   ${EndIf}
 
-  ${If} ${FileExists} "C:\Program Files (x86)\Lenovo\Energy Management\Energy Management.exe"
+  ${If} ${FileExists} "$PROGRAMFILES32\Lenovo\Energy Management\Energy Management.exe"
     Return
   ${EndIf}
 
   StrCpy $0 1
 FunctionEnd
 
 Section
 SectionEnd