From: "Ludovic Courtès" <ludo@gnu.org>
To: 68087-done@debbugs.gnu.org
Subject: bug#68087: Signal handlers not called after ‘primitive-fork’
Date: Wed, 24 Jan 2024 11:34:57 +0100 [thread overview]
Message-ID: <87h6j3uii6.fsf_-_@gnu.org> (raw)
In-Reply-To: <20240105181404.2181-1-ludo@gnu.org> ("Ludovic Courtès"'s message of "Fri, 5 Jan 2024 19:14:04 +0100")
Ludovic Courtès <ludo@gnu.org> skribis:
> Fixes <https://bugs.gnu.org/68087>.
>
> * libguile/scmsigs.h (scm_i_signals_pre_fork, scm_i_signals_post_fork):
> New declarations.
> (scm_i_signal_delivery_thread): Change type to SCM..
> * libguile/threads.c (scm_all_threads): Adjust accordingly and exclude
> threads that have ‘t->exited’. Access ‘thread_count’ after grabbing
> ‘thread_admin_mutex’.
> * libguile/posix.c (scm_fork): Add calls to ‘scm_i_signals_pre_fork’ and
> ‘scm_i_signals_post_fork’.
> * libguile/scmsigs.c (signal_delivery_thread): Close signal_pipe[0] upon
> exit and set it to -1.
> (once): New file-global variable, moved from…
> (scm_i_ensure_signal_delivery_thread): … here.
> (stop_signal_delivery_thread, scm_i_signals_pre_fork)
> (scm_i_signals_post_fork): New functions.
> * test-suite/standalone/test-sigaction-fork: New file.
> * test-suite/standalone/Makefile.am (check_SCRIPTS, TESTS): Add it.
Pushed as 5a8502a4946e8a5b5c40a127aa240fc6ad960d03.
Ludo’.
prev parent reply other threads:[~2024-01-24 10:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-28 17:16 bug#68087: Signal handlers not called after ‘primitive-fork’ Ludovic Courtès
2024-01-05 18:14 ` bug#68087: [PATCH] Stop signal thread before forking, restart it afterwards Ludovic Courtès
2024-01-24 10:34 ` Ludovic Courtès [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87h6j3uii6.fsf_-_@gnu.org \
--to=ludo@gnu.org \
--cc=68087-done@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).