If `join-thread' timeout, the thread mutex is not unlocked, resulting in
deadlock to the next call to it or deadlock of the thread itself when it
terminates.
Thus, always unlock the mutex.
Fix: #55356
* module/ice-9/threads.scm (join-thread): Always unlock thread mutex.
* test-suite/tests/thread
(sigaction SIGINT
(car handler+flags)
(cdr handler+flags))
--8<---cut here---end--->8---
Thanks,
Olivier
--
Olivier Dion
oldiob.ca
t-9.scm" 1752 10)
See how the columns for foo.scm are weird:
foo.scm:15:20:
(let ((stack (make-stack #t)))
^
foo.scm:8:13:
(lambda () (throw 'bar)))
^
When I would have expected the following:
foo.scm:15:20:
(let ((stack (make-stack #t)))
is file is part of Guile.
> @@ -47,6 +47,7 @@
> #include "dynwind.h"
> #include "eval.h"
> #include "extensions.h"
> +#include "finalizers.h"
> #include "fluids.h"
> #include "gc-inline.h"
> #include "gc.h"
> @@ -1691,7 +1692,9 @@ SCM_DEFINE (scm_all_threads, "all-threads", 0, 0, 0,
>
>for (t = all_threads; t && n > 0; t = t->next_thread)
> {
> - if (!t->exited && !scm_i_is_signal_delivery_thread (t))
> + if (!t->exited
> + && !scm_i_is_signal_delivery_thread (t)
> + && !scm_i_is_finalizer_thread (t))
> {
> SCM_SETCAR (*l, t->handle);
> l = SCM_CDRLOC (*l);
>
> base-commit: f6359a4715d023761454f1bf945633ce4cca98fc
> --
> 2.48.1
>
>
>
--
Olivier Dion
EfficiOS Inc.
https://www.efficios.com