reap child processes
This commit is contained in:
@@ -1,5 +1,13 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
reap() {
|
||||||
|
kill -TERM $child
|
||||||
|
sleep 0.1
|
||||||
|
exit
|
||||||
|
}
|
||||||
|
|
||||||
|
trap reap TERM INT
|
||||||
|
|
||||||
# If a command fails, exit the script
|
# If a command fails, exit the script
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user