aboutsummaryrefslogtreecommitdiff
path: root/src/connection.lisp
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-07-15 13:50:34 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-07-15 13:51:25 -0700
commit58bcd1fa4a00c35492d6886c0f729974e7028136 (patch)
tree6eb97bed6e60a439b79fed270a63dac82fe27f2b /src/connection.lisp
parent4c7869bb07cb7ae36a9ea300996940ee5570c92c (diff)
downloadconsfigurator-58bcd1fa4a00c35492d6886c0f729974e7028136.tar.gz
MKTEMP: avoid returning an empty string
m4(1) can exit zero but fail to create a temporary file. Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/connection.lisp')
-rw-r--r--src/connection.lisp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/connection.lisp b/src/connection.lisp
index b2b0cac..7dbe5d3 100644
--- a/src/connection.lisp
+++ b/src/connection.lisp
@@ -289,7 +289,7 @@ which will be cleaned up when BODY is finished."
#?"umask 077; echo 'mkstemp(${template})' 2>/dev/null | m4 2>/dev/null || mktemp '${template}'"
nil)
(let ((lines (lines out)))
- (if (and (zerop exit) lines)
+ (if (and (zerop exit) lines (plusp (length (car lines))))
(car lines)
(error 'run-failed
:cmd "(attempt to make a temporary file on remote)"