Skip to content

Commit

Permalink
Fall back to WinDbg if WinDbgX is not installed (microsoft#3342)
Browse files Browse the repository at this point in the history
  • Loading branch information
mtfriesen authored Jan 10, 2023
1 parent 54ff366 commit 46acb24
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion scripts/run-executable.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,11 @@ function Start-Executable {
}
}
if ($Debugger) {
$pinfo.FileName = "windbgx"
if (Get-Command "windbgx.exe" -ErrorAction SilentlyContinue) {
$pinfo.FileName = "windbgx.exe"
} else {
$pinfo.FileName = "windbg.exe"
}
if ($InitialBreak) {
$pinfo.Arguments = "-G $($Path) $($Arguments)"
} else {
Expand Down
6 changes: 5 additions & 1 deletion scripts/run-gtest.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,11 @@ function Start-TestExecutable([String]$Arguments, [String]$OutputDir) {
$pinfo = New-Object System.Diagnostics.ProcessStartInfo
if ($IsWindows) {
if ($Debugger) {
$pinfo.FileName = "windbgx"
if (Get-Command "windbgx.exe" -ErrorAction SilentlyContinue) {
$pinfo.FileName = "windbgx.exe"
} else {
$pinfo.FileName = "windbg.exe"
}
if ($InitialBreak) {
$pinfo.Arguments = "-G $($Path) $($Arguments)"
} else {
Expand Down

0 comments on commit 46acb24

Please sign in to comment.