~ chicken-core (chicken-5) 3ee08462294b9bf7d1f601afcf97991b51b84782
commit 3ee08462294b9bf7d1f601afcf97991b51b84782 Author: felix <felix@call-with-current-continuation.org> AuthorDate: Thu Oct 21 03:56:08 2010 -0400 Commit: felix <felix@call-with-current-continuation.org> CommitDate: Thu Oct 21 03:56:08 2010 -0400 catch negative timeout values in ##sys#thread-block-for-timeout diff --git a/scheduler.scm b/scheduler.scm index c247a29f..6d194209 100644 --- a/scheduler.scm +++ b/scheduler.scm @@ -236,7 +236,8 @@ EOF (define (##sys#thread-block-for-timeout! t tm) (dbg t " blocks for timeout " tm) - (unless (flonum? tm) ; to catch old code that uses fixum timeouts + (unless (and (flonum? tm) ; to catch old code that uses fixum timeouts + (fp> tm 0)) (panic "##sys#thread-block-for-timeout!: invalid timeout")) ;; This should really use a balanced tree: (let loop ([tl ##sys#timeout-list] [prev #f])Trap