git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Stephen R. van den Berg" <srb@cuci.nl>
Cc: git@vger.kernel.org, Johannes Schindelin <Johannes.Schindelin@gmx.de>
Subject: Re: [PATCH 2/3] git-daemon: make the signal handler almost a no-op
Date: Thu, 14 Aug 2008 01:26:32 -0700	[thread overview]
Message-ID: <7vljz0dmtj.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20080814074717.GC9680@cuci.nl> (Stephen R. van den Berg's message of "Thu, 14 Aug 2008 09:47:17 +0200")

"Stephen R. van den Berg" <srb@cuci.nl> writes:

> Solution A is what you propose, but which I find less appealing because
> any future magic to actually setup the handler needs to be maintained
> and updated in two places.

Well, A is attractive because it leaves the window open for us to later
not rearming it unconditionally from child_handler().  I happen to think
that the interface we will use to call "signal()" is much less likely to
change than what we would do in child_handler().

> Solution C is what follows your train of thought better, because it
> future-proofs the setup as well as the handler.

Surely, we could take this route as the logical conclusion from my
maintainability concerns, except that, if we are to make things as fine
grained as you suggest, we would definitely will not have a single
"setup", but "setup" and "rearm" as separate functions.  Perhaps "setup"
may start using sigaction() with SA_RESETHAND cleared, and we can make
"rearm" truly a no-op everywhere.

 

  reply	other threads:[~2008-08-14  8:27 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-13  8:43 [PATCH 1/3] git-daemon: logging done right Stephen R. van den Berg
2008-08-13  8:43 ` [PATCH 2/3] git-daemon: make the signal handler almost a no-op Stephen R. van den Berg
2008-08-14  0:09   ` Junio C Hamano
2008-08-14  0:18     ` Stephen R. van den Berg
2008-08-14  1:09       ` Junio C Hamano
2008-08-14  7:47         ` Stephen R. van den Berg
2008-08-14  8:26           ` Junio C Hamano [this message]
2008-08-14 10:13             ` Stephen R. van den Berg
2008-08-14 13:41   ` Johannes Schindelin
2008-08-13  8:43 ` [PATCH 3/3] git-daemon: rewrite kindergarden Stephen R. van den Berg
2008-08-13  8:58   ` Stephen R. van den Berg
2008-08-13  9:00   ` [PATCH] " Stephen R. van den Berg
2008-08-13 10:40     ` [PATCH] git-daemon: rewrite kindergarden, new option --max-connections Stephen R. van den Berg
2008-08-13  9:05   ` [PATCH 3/3] git-daemon: rewrite kindergarden Petr Baudis
2008-08-13 10:37     ` Stephen R. van den Berg
2008-08-13 23:13 ` [PATCH 1/3] git-daemon: logging done right Junio C Hamano

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=7vljz0dmtj.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=srb@cuci.nl \
    /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 NNTP newsgroup(s).