Skip to content

Commit 80421cd

Browse files
authored
Add exception handling to TerminateProcess (#9573)
1 parent ad6f47e commit 80421cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Files.FullTrust/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ private static void TerminateProcess(int processId)
269269
#if DEBUG
270270
// In debug mode this kills this process too??
271271
#else
272-
Process.GetProcessById(processId).Kill();
272+
SafetyExtensions.IgnoreExceptions(() => Process.GetProcessById(processId).Kill(), Program.Logger);
273273
#endif
274274
}
275275
}

0 commit comments

Comments
 (0)