From adb79ae3320aac4926be0b325b103e360dc1123b Mon Sep 17 00:00:00 2001 From: wileyhy <84648683+wileyhy@users.noreply.github.com> Date: Thu, 29 Jun 2023 07:53:48 -0700 Subject: [PATCH] Add four varying examples found in the wild of problematic code --- SC2064.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/SC2064.md b/SC2064.md index 9ee512a..4ad78a3 100644 --- a/SC2064.md +++ b/SC2064.md @@ -4,6 +4,10 @@ ```sh trap "echo \"Finished on $(date)\"" EXIT +trap "rm -fr '$testdir1' '$testdir2'" $TRAP_SIGNALS +trap "rm $tmp" $TRAP_SIGNALS +trap "${remove_aar_temp}" SIGKILL SIGTERM SIGQUIT EXIT +trap "$(shopt -p extglob)" RETURN ``` ### Correct code: