Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -277,12 +277,19 @@ static async Task KillTreeAsyncInternal (int pid, ILog log, bool? diagnostics =

// Send SIGABRT since that produces a crash report
// lldb may fail to attach to system processes, but crash reports will still be produced with potentially helpful stack traces.
for (int i = 0; i < pids.Count; i++)
for (int i = 0; i < pids.Count; i++) {
log.WriteLine ($"kill -6 {pids [i]}");
kill (pids [i], 6);
}

// Wait a little bit for the OS to process the SIGABRTs
await Task.Delay (TimeSpan.FromSeconds (5));

// send kill -9 anyway as a last resort
for (int i = 0; i < pids.Count; i++)
for (int i = 0; i < pids.Count; i++) {
log.WriteLine ($"kill -9 {pids [i]}");
kill (pids [i], 9);
}
}

static async Task<bool> WaitForExitAsync (Process process, TimeSpan? timeout = null)
Expand Down