Skip to content

env: --list-signal-handling lists env's own changes, not the state of the signals #15185

Closed

Description

@NdekoCode

GNU env --list-signal-handling prints, on stderr, every signal that is not at its default once the signal options have been applied, whether env changed it or inherited it, with BLOCK and IGNORE as the possible states and the number padded to two characters:

$ env --default-signal=PIPE --list-signal-handling true
$ env --ignore-signal=INT --block-signal=INT --list-signal-handling true
INT        ( 2): BLOCK,IGNORE
$ (trap '' PIPE; env --list-signal-handling true)
PIPE       (13): IGNORE

uutils lists the actions it was asked for instead, so it prints PIPE (13): DEFAULT for the first, INT (2): IGNORE for the second (the number not padded, the block lost) and nothing for the third. GNU 9.12 and uutils main at a5bc606. Part of what env/env-signal-handler.sh in #14705 exercises.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions