test22.sh 156 B

1234567891011121314151617
  1. #! ./testshell
  2. traph ()
  3. {
  4. trap 2
  5. kill -2 $$
  6. echo 'Survived!'
  7. }
  8. echo 'You should be able to kill this script with just one SIGINT'
  9. cat
  10. cat
  11. cat
  12. cat
  13. cat