aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bash/bashrc.d/fnl.bash5
-rwxr-xr-xbin/edda2
-rwxr-xr-xbin/han2
3 files changed, 4 insertions, 5 deletions
diff --git a/bash/bashrc.d/fnl.bash b/bash/bashrc.d/fnl.bash
index 408778a2..fd8dfc97 100644
--- a/bash/bashrc.d/fnl.bash
+++ b/bash/bashrc.d/fnl.bash
@@ -23,9 +23,8 @@ fnl() {
fi
# Create a temporary directory or bail
- local template dirname
- template=$FUNCNAME.$1.XXXXX
- if ! dirname=$(mktemp -dt -- "$template") ; then
+ local dirname
+ if ! dirname=$(mktemp -dt -- "$FUNCNAME"."$1".XXXXXX) ; then
return
fi
diff --git a/bin/edda b/bin/edda
index f0d716d7..996ed2a5 100755
--- a/bin/edda
+++ b/bin/edda
@@ -51,7 +51,7 @@ for arg ; do
done
# Duplicate stdin into a file, which we'll remove on exit
-stdin=$(mktemp) || exit
+stdin=$(mktemp -dt "$self".XXXXXX) || exit
cleanup() {
rm -f -- "$stdin"
}
diff --git a/bin/han b/bin/han
index 755710d5..7eea8b46 100755
--- a/bin/han
+++ b/bin/han
@@ -36,7 +36,7 @@ if ((BASH_VERSINFO[0] >= 4)) ; then
fi
# Create a temporary file and set up a trap to get rid of it.
-tmpdir=$(mktemp -dt "$self".XXXXX) || exit
+tmpdir=$(mktemp -dt "$self".XXXXXX) || exit
cleanup() {
rm -fr -- "$tmpdir"
}