Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Mar 2011 20:01:46 +0000
From:      Chris Rees <utisoft@gmail.com>
To:        Chris Rees <utisoft@gmail.com>, freebsd-standards@freebsd.org,  Maxim Konovalov <maxim.konovalov@gmail.com>, Oliver Fromme <olli@lurza.secnetix.de>
Cc:        David Schultz <das@freebsd.org>
Subject:   Re: dd dies on SIGUSR1
Message-ID:  <AANLkTi=PE6beTB1wmC8v41PqAWWSqq%2B6z-Be44uePYtZ@mail.gmail.com>
In-Reply-To: <20110322181604.GA47588@zim.MIT.EDU>
References:  <AANLkTikoZNpmM83%2BU-0AWhO43K67gKNq1dZ4UnL2UAPo@mail.gmail.com> <201103221457.p2MEvJub035858@lurza.secnetix.de> <AANLkTinzhKi-sfW-kz9W6EkA0WtB5-nO0gpyCLRyyHCn@mail.gmail.com> <20110322181604.GA47588@zim.MIT.EDU>

next in thread | previous in thread | raw e-mail | index | archive | help
On 22 March 2011 18:16, David Schultz <das@freebsd.org> wrote:
> On Tue, Mar 22, 2011, Chris Rees wrote:
>> Since POSIX has SIGUSR[12] as undefined, I think it's a POLA violation
>> to have processes die when provided.
>
> Quite the contrary: The default behavior of SIGUSR1 on FreeBSD
> follows both POSIX and historical precedent, so changing it would
> be a violation of POLA. =A0Terminating the process is also the
> default on Linux.

However... I still think that because no-one in their right mind would
use SIGUSR[12] to terminate a program it's pointless for it to happen,
and can only cause annoyance.

People want to hold onto historical behaviour for no good reason, and
I feel that this is one of these occasions. There is no reason for it
apart from 'that's how it always has been [because no-one's
complained]'. I also disagree that it 'follows' POSIX, POLA *IMO* for
undefined behaviour is generally do nothing or report an error.

> Linux dd's interpretation of SIGUSR1 seems rather poorly
> considered, since as you note, utilities that don't handle it will
> simply die unexpectedly. =A0However, it certainly wouldn't hurt to
> patch FreeBSD's dd to handle SIGUSR1 the same way as SIGINFO.
>

Could the original patch in the PR be good enough then?

Thank you for the thoughts.

I'm sorry if I seem to be ranting, and I fully understand if my
proposal of changing the default of USR1 is rejected completely; I
just wanted to have a reasoned discussion.

David, if you think the original patch (which does what your last
paragraph says) is OK then feel free to take that as the Fix.

Thanks!

Chris



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTi=PE6beTB1wmC8v41PqAWWSqq%2B6z-Be44uePYtZ>