MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / TryKillProcess

Method TryKillProcess

dotnet/src/webdriver/DriverService.cs:488–504  ·  view source on GitHub ↗
(Process process)

Source from the content-addressed store, hash-verified

486 }
487
488 private void TryKillProcess(Process process)
489 {
490 try
491 {
492 if (!process.HasExited)
493 {
494 process.Kill();
495 }
496 }
497 catch (Exception ex) when (ex is InvalidOperationException or System.ComponentModel.Win32Exception)
498 {
499 if (_logger.IsEnabled(LogEventLevel.Debug))
500 {
501 _logger.Debug($"Failed to kill process: {ex.Message}");
502 }
503 }
504 }
505
506 /// <summary>
507 /// Waits until the service is initialized, or the timeout set

Callers

nothing calls this directly

Calls 2

IsEnabledMethod · 0.45
DebugMethod · 0.45

Tested by

no test coverage detected