Changeset 15207 in project for chicken/trunk


Ignore:
Timestamp:
07/12/09 21:44:51 (10 years ago)
Author:
felix winkelmann
Message:

create-temporary-file uses /tmp, if no suitable env. var is found

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/files.scm

    r15149 r15207  
    330330        [call-with-output-file call-with-output-file] )
    331331    (lambda ext
    332       (let ([dir (or (get-environment-variable "TMPDIR")
     332      (let ((dir (or (get-environment-variable "TMPDIR")
    333333                     (get-environment-variable "TEMP")
    334                      (get-environment-variable "TMP"))]
    335             [ext (if (pair? ext) (car ext) "tmp")])
     334                     (get-environment-variable "TMP")
     335                     (file-exists? "/tmp")))
     336            (ext (if (pair? ext) (car ext) "tmp")))
    336337        (##sys#check-string ext 'create-temporary-file)
    337338        (let loop ()
Note: See TracChangeset for help on using the changeset viewer.