diff --git a/src/Proto.Actor/Utils/TaskFactory.cs b/src/Proto.Actor/Utils/TaskFactory.cs index 961f9643a3..5f118f8b0e 100644 --- a/src/Proto.Actor/Utils/TaskFactory.cs +++ b/src/Proto.Actor/Utils/TaskFactory.cs @@ -17,7 +17,7 @@ public static class SafeTask private static readonly ILogger Logger = Log.CreateLogger(); /// - /// Runs a task and handles exceptions. If is thrown, it is ignored. + /// Runs a task and handles exceptions. If or is thrown, it is ignored. /// If any other exception is thrown, it is logged. /// /// @@ -34,6 +34,10 @@ public static async Task Run(Func body, CancellationToken cancellationToke { // Pass. Do not log when the task is canceled. } + catch (OperationCanceledException) + { + // Pass. Do not log when the operation is canceled. + } catch (Exception x) { x.CheckFailFast();