From 3f6a5bb5ef72071290cad9b7c08749c1f2530031 Mon Sep 17 00:00:00 2001 From: Jay McCarthy Date: Fri, 23 Mar 2012 10:44:43 -0600 Subject: [PATCH] Fixing the error message from PR12443 original commit: 9b579d8c2aa8548e6b49c9aeec0a7a4cf107bd58 --- collects/mzlib/thread.rkt | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/collects/mzlib/thread.rkt b/collects/mzlib/thread.rkt index 0f2b955..ab84274 100644 --- a/collects/mzlib/thread.rkt +++ b/collects/mzlib/thread.rkt @@ -112,8 +112,14 @@ ;; Enable breaking: (when can-break? (break-enabled #t)) - ;; Call the handler - (handler r w)))))]) + ;; Prevent the handler from + ;; killing this custodian, by + ;; creating an intermediary, + ;; but child custodian + (parameterize ([current-custodian + (make-custodian)]) + ;; Call the handler + (handler r w))))))]) ;; Clean-up and timeout thread: (thread (lambda ()