all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Mathieu Othacehe <othacehe@gnu.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 41507@debbugs.gnu.org
Subject: [bug#41507] [PATCH Shepherd 2/2] shepherd: Use 'signalfd' when possible.
Date: Tue, 02 Jun 2020 09:00:20 +0200	[thread overview]
Message-ID: <87imgax88r.fsf@gnu.org> (raw)
In-Reply-To: <87tuzxs4gj.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Sat, 30 May 2020 19:44:12 +0200")


Hey Ludo,

> That way, the child is guaranteed to never execute the original
> handlers, and neither the parent nor the child misses any of these
> signals (previously, the temporary (sigaction SIGTERM SIG_DFL)
> introduced a window during which shepherd could be killed by a SIGTERM
> instead of handling it gracefully.)
>
> WDYT?

Yes, this is indeed much better this way!

> +(define %precious-signals
> +  ;; Signals that the shepherd process handles.
> +  (list SIGCHLD SIGINT SIGHUP SIGTERM))

We could maybe factorize this list with the one in "signal-port" in the
"main" procedure. This way if we ever add an extra signal, we do not
forget to add it to blocked signals list.

Otherwise, this looks fine, thanks for taking care of that :)

Mathieu




  reply	other threads:[~2020-06-02  7:01 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-24 14:27 [bug#41507] [PATCH Shepherd 0/2] Use 'signalfd' on GNU/Linux Ludovic Courtès
2020-05-24 14:36 ` [bug#41507] [PATCH Shepherd 1/2] system: Add support for 'signalfd' Ludovic Courtès
2020-05-24 14:37   ` [bug#41507] [PATCH Shepherd 2/2] shepherd: Use 'signalfd' when possible Ludovic Courtès
2020-05-25 12:31     ` Mathieu Othacehe
2020-05-26 22:13       ` bug#41507: " Ludovic Courtès
2020-05-27  5:45         ` [bug#41507] " Jan Nieuwenhuizen
2020-05-27  9:23           ` Ludovic Courtès
2020-05-30 17:44       ` Ludovic Courtès
2020-06-02  7:00         ` Mathieu Othacehe [this message]
2020-06-02 21:38           ` Ludovic Courtès
2020-05-24 15:13 ` [bug#41507] [PATCH Shepherd 0/2] Use 'signalfd' on GNU/Linux Jelle Licht
2020-05-25  7:37   ` Ludovic Courtès
2020-05-25  8:02     ` Jelle Licht
2020-05-26 21:32       ` Ludovic Courtès

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87imgax88r.fsf@gnu.org \
    --to=othacehe@gnu.org \
    --cc=41507@debbugs.gnu.org \
    --cc=ludo@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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.