xref: /freebsd/bin/sh/tests/builtins/wait4.0 (revision 8aac90f18aef7c9eea906c3ff9a001ca7b94f375)
1
2T=`mktemp -d ${TMPDIR:-/tmp}/sh-test.XXXXXX`
3trap 'rm -rf $T' 0
4cd $T || exit 3
5mkfifo fifo1
6trapped=
7trap trapped=1 QUIT
8{ kill -QUIT $$; sleep 1; exit 4; } >fifo1 &
9wait $! <fifo1
10r=$?
11[ "$r" -gt 128 ] && [ -n "$trapped" ]
12