install: only create TMPDIR if missing
This commit is contained in:
parent
823e1017d8
commit
0bf52b73f4
|
@ -348,10 +348,9 @@ _sudo() {
|
|||
fi
|
||||
}
|
||||
|
||||
|
||||
# Ensure that $TMPDIR exists if defined.
|
||||
if [[ -v TMPDIR ]]; then
|
||||
mkdir -m 0700 -p "$TMPDIR"
|
||||
if [[ -n "${TMPDIR:-}" ]] && [[ ! -d "${TMPDIR:-}" ]]; then
|
||||
mkdir -m 0700 -p "${TMPDIR:-}"
|
||||
fi
|
||||
|
||||
readonly SCRATCH=$(mktemp -d)
|
||||
|
|
Loading…
Reference in a new issue