[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] trap -p does not display ignored signals inherited from pare
From: |
Eric Blake |
Subject: |
Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process |
Date: |
Tue, 23 Mar 2010 08:16:55 -0600 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.8) Gecko/20100301 Fedora/3.0.3-1.fc12 Lightning/1.0b1 Thunderbird/3.0.3 |
On 03/23/2010 01:29 AM, Siddhesh Poyarekar wrote:
> Steps to Reproduce:
> 1. trap '' SIGINT
> 2. exec bash
> 3. trap -p
POSIX states:
"Signals that were ignored on entry to a non-interactive shell cannot be
trapped or reset, although no error need be reported when attempting to
do so. An interactive shell may reset or catch signals ignored on entry."
http://www.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#trap
I see no bug - bash is within its rights to pretend that an inherited
ignored SIGINT has no trap setting, seeing as how the user cannot modify
that through any use of trap. That is, 'trap -p' is designed to output
the text that will restore traps to their normal state, but since there
is no way to change the state of SIGINT from being ignored, there is
nothing needed in the output.
--
Eric Blake eblake@redhat.com +1-801-349-2682
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/23
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process,
Eric Blake <=
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/23
- Message not available
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Eric Blake, 2010/03/25
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/25
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Eric Blake, 2010/03/25
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/25
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Eric Blake, 2010/03/25
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/26
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Siddhesh Poyarekar, 2010/03/26
- Re: [PATCH] trap -p does not display ignored signals inherited from parent by a bash process, Chet Ramey, 2010/03/26