diff options
author | Samuel Williams <[email protected]> | 2025-06-10 16:30:43 +0900 |
---|---|---|
committer | GitHub <[email protected]> | 2025-06-10 07:30:43 +0000 |
commit | cdeedd5bc1a3c712f7f7b8c2409906a0b5ed9e37 (patch) | |
tree | 169489b6771c4670801042ee95e27732855b3892 /scheduler.c | |
parent | 20adae4ad6c20aa5918e00f60e956fe9051a7ead (diff) |
Fix handling of cancelled blocking operations. (#13570)
Notes
Notes:
Merged-By: ioquatix <[email protected]>
Diffstat (limited to 'scheduler.c')
-rw-r--r-- | scheduler.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/scheduler.c b/scheduler.c index 80c0278933..11faca01d3 100644 --- a/scheduler.c +++ b/scheduler.c @@ -1061,9 +1061,8 @@ VALUE rb_fiber_scheduler_blocking_operation_wait(VALUE scheduler, void* (*functi operation->data2 = NULL; operation->unblock_function = NULL; - // If the blocking operation was never executed, return Qundef to signal - // the caller to use rb_nogvl instead - if (current_status != RB_FIBER_SCHEDULER_BLOCKING_OPERATION_STATUS_COMPLETED) { + // If the blocking operation was never executed, return Qundef to signal the caller to use rb_nogvl instead + if (current_status == RB_FIBER_SCHEDULER_BLOCKING_OPERATION_STATUS_QUEUED) { return Qundef; } |