From fa139471b3706df59bd3292fab4e497a9262e75e Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Wed, 5 Sep 2018 18:26:12 -0700 Subject: [PATCH] Reset start times of threads when restoring image. --- src/runtime/thread.scm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/runtime/thread.scm b/src/runtime/thread.scm index 19c163e24..3fb29d404 100644 --- a/src/runtime/thread.scm +++ b/src/runtime/thread.scm @@ -178,7 +178,12 @@ USA. (define (reset-threads-high!) (set! io-registry (and have-select? (make-select-registry))) (set! io-registrations #f) - (set! subprocess-registrations '())) + (set! subprocess-registrations '()) + (map-over-population! thread-population + (let ((times (get-system-times))) + (lambda (thread) + (if (thread/start-times thread) + (set-thread/start-times! thread times)))))) (define (make-thread continuation) (let ((thread (%make-thread (make-1d-table)))) -- 2.25.1