dotoold: improve signal handling
This commit is contained in:
parent
217525bf2f
commit
4fb2cb37bf
1 changed files with 4 additions and 3 deletions
7
dotoold
7
dotoold
|
@ -19,7 +19,8 @@ if fifo_being_read "$p" 2> /dev/null; then
|
|||
fi
|
||||
|
||||
rm -rf "$p" || exit 1
|
||||
trap 'rm -rf "$p"' EXIT INT TERM HUP
|
||||
trap 'rm -rf "$p"; trap - EXIT; exit' EXIT INT TERM HUP
|
||||
mkfifo -m 660 "$p" || exit 1
|
||||
|
||||
dotool <> "$p"
|
||||
dotool <> "$p" &
|
||||
wait
|
||||
pkill -P $$
|
||||
|
|
Loading…
Reference in a new issue