From 15790d6d544605f24a660190e782e2d4dff17833 Mon Sep 17 00:00:00 2001 From: Taylor R Campbell Date: Fri, 14 Nov 2014 04:47:04 +0000 Subject: [PATCH] Don't let just any event wake THREAD-JOIN. --- tests/runtime/test-thread-queue.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/runtime/test-thread-queue.scm b/tests/runtime/test-thread-queue.scm index 6f86b7d57..186bb7e78 100644 --- a/tests/runtime/test-thread-queue.scm +++ b/tests/runtime/test-thread-queue.scm @@ -56,14 +56,15 @@ USA. (thread-join consumer))) (define (thread-join thread) - (let ((value)) + (let ((done? #f) (value)) (with-thread-events-blocked (lambda () (join-thread thread (lambda (thread v) (declare (ignore thread)) (set! value v) + (set! done? #t) #f)) - (suspend-current-thread) + (do () (done?) (suspend-current-thread)) value)))) (define-test 'thread-queue -- 2.25.1