trap: Implement POSIX.1-2008 trap reset behaviour

Jonathan Perkin submitted a patch to fix the behaviour of trap
when the first argument is an integer.  Currently it is treated
as a command while POSIX requires it to be treated as a signal.

This patch is based on his idea but instead of adding an extra
argument to decode_signal I have added a new decode_signum helper.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
1 file changed
tree: fe196361b9b00c679d6c652a18d29f47eaf0f65c
  1. src/
  2. autogen.sh
  3. ChangeLog
  4. ChangeLog.O
  5. configure.ac
  6. COPYING
  7. Makefile.am