Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 16 Jan 2011 13:56:41 +0000 (UTC)
From:      Jilles Tjoelker <jilles@FreeBSD.org>
To:        cvs-src-old@freebsd.org
Subject:   cvs commit: src/bin/sh trap.c src/tools/regression/bin/sh/builtins trap6.0
Message-ID:  <201101161357.p0GDvxou082966@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help

jilles      2011-01-16 13:56:41 UTC

  FreeBSD src repository

  Modified files:
    bin/sh               trap.c 
  Added files:
    tools/regression/bin/sh/builtins trap6.0 
  Log:
  SVN rev 217472 on 2011-01-16 13:56:41Z by jilles
  
  sh: If exit is used without args from a trap action, exit on the signal.
  
  This is useful so that it is easier to exit on a signal than to reset the
  trap to default and resend the signal. It matches ksh93. POSIX says that
  'exit' without args from a trap action uses the exit status from the last
  command before the trap, which is different from 'exit $?' and matches this
  if the previous command is assumed to have exited on the signal.
  
  If the signal is SIGSTOP, SIGTSTP, SIGTTIN or SIGTTOU, or if the default
  action for the signal is to ignore it, a normal _exit(2) is done with exit
  status 128+signal_number.
  
  Revision  Changes    Path
  1.43      +22 -3     src/bin/sh/trap.c
  1.1       +9 -0      src/tools/regression/bin/sh/builtins/trap6.0 (new)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201101161357.p0GDvxou082966>