Update of /cvsroot/scsh/scsh-0.6/scheme/rts
In directory usw-pr-cvs1:/tmp/cvs-serv12114
Modified Files:
thread.scm
Log Message:
Bug fix:
I had forgotten to mark the thread-cell value environment as read-only
when it's passed on to a spawned thread. Do that now.
Index: thread.scm
===================================================================
RCS file: /cvsroot/scsh/scsh-0.6/scheme/rts/thread.scm,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** thread.scm 2001/05/22 14:58:15 1.2
--- thread.scm 2001/05/28 13:31:01 1.3
***************
*** 550,553 ****
--- 550,554 ----
(define (spawn thunk . id)
+ (set-thread-own-values?! (current-thread) #f)
(apply spawn-on-scheduler
(thread-scheduler (current-thread))
***************
*** 558,566 ****
(define (spawn-on-root thunk . id)
(if (root-scheduler)
! (apply spawn-on-scheduler
! (root-scheduler)
! thunk
! (thread-cell-values (current-thread))
! id)
(thunk)))
--- 559,569 ----
(define (spawn-on-root thunk . id)
(if (root-scheduler)
! (begin
! (set-thread-own-values?! (current-thread) #f)
! (apply spawn-on-scheduler
! (root-scheduler)
! thunk
! (thread-cell-values (current-thread))
! id))
(thunk)))
|