ash: hopefully close bug 4324. With testcase.

function                                             old     new   delta
evaltree                                             621     869    +248
popstring                                            134     140      +6
This commit is contained in:
Denis Vlasenko
2008-07-26 13:45:57 +00:00
parent 2b2e267b43
commit 4e19a9c81a
3 changed files with 57 additions and 17 deletions

View File

@@ -0,0 +1,3 @@
sleeping
child exits as expected
parent exits

View File

@@ -0,0 +1,18 @@
#!/bin/sh
$THIS_SH -c '
cleanup() {
echo "child exits as expected"
exit
}
trap cleanup HUP
echo "sleeping"
sleep 1
echo "BAD exit from child!"
' &
child=$!
sleep 0.1 # let child install handler first
kill -HUP $child
wait
echo "parent exits"