summaryrefslogtreecommitdiff
path: root/src/mongo/executor
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/executor')
-rw-r--r--src/mongo/executor/task_executor.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/mongo/executor/task_executor.cpp b/src/mongo/executor/task_executor.cpp
index 1f3fe80e6bc..89b136a3fee 100644
--- a/src/mongo/executor/task_executor.cpp
+++ b/src/mongo/executor/task_executor.cpp
@@ -95,8 +95,12 @@ ExecutorFuture<Response> wrapScheduleCallWithCancelTokenAndFuture(
// Fail point to make this method to wait until the token is canceled.
if (!token.isCanceled()) {
- pauseScheduleCallWithCancelTokenUntilCanceled.pauseWhileSetAndNotCanceled(
- Interruptible::notInterruptible(), token);
+ try {
+ pauseScheduleCallWithCancelTokenUntilCanceled.pauseWhileSetAndNotCanceled(
+ Interruptible::notInterruptible(), token);
+ } catch (ExceptionFor<ErrorCodes::Interrupted>&) {
+ // Swallow the interrupted exception that arrives from canceling a failpoint.
+ }
}
auto scheduleStatus = wrapCallbackHandleWithCancelToken(