diff --git a/file.scm b/file.scm index 11b1bcc0..f61961d0 100644 --- a/file.scm +++ b/file.scm @@ -312,10 +312,10 @@ EOF (let ((tmp (or (get-environment-variable "TMPDIR") (get-environment-variable "TEMP") - (get-environment-variable "TMP") - "/tmp"))) - (set! temp tmp) - tmp))) + (get-environment-variable "TMP")))) + (when tmp + (set! temp tmp)) + (or tmp "/tmp")))) (set! create-temporary-file (lambda (#!optional (ext "tmp")) (##sys#check-string ext 'create-temporary-file)