File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ if ([string]::IsNullOrWhiteSpace($installRootRaw)) {
1919 exit 0
2020}
2121
22- $installRoot = $installRootRaw.ToLowerInvariant ()
22+ $installRoot = $installRootRaw
2323$installRootWithSep = $installRoot + [string ][char ]92
2424$currentPid = $PID
2525$targetProcessNames = @ (
@@ -40,8 +40,8 @@ function Test-IsUnderInstallRoot {
4040 }
4141
4242 try {
43- $normalized = [System.IO.Path ]::GetFullPath($PathValue ).TrimEnd([char ]92 ).ToLowerInvariant()
44- return $normalized -eq $installRoot -or $normalized.StartsWith ($installRootWithSep )
43+ $normalized = [System.IO.Path ]::GetFullPath($PathValue ).TrimEnd([char ]92 )
44+ return $normalized -ieq $installRoot -or $normalized.StartsWith ($installRootWithSep , [ System.StringComparison ]::OrdinalIgnoreCase )
4545 } catch {
4646 return $false
4747 }
You can’t perform that action at this time.
0 commit comments