summaryrefslogtreecommitdiff
path: root/lib/libsndio/aucat.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2019-06-28 05:35:36 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2019-06-28 05:35:36 +0000
commitdb251f9c53ebe82df0e02b3d742581fd8b421989 (patch)
tree2483bb2028ba9c0fe193188d9d466ea52a607aaa /lib/libsndio/aucat.c
parentb75b34ab97c5e2b3d1cc4fae079092b6d7d399a3 (diff)
mkstemp() returns -1 on failure
Diffstat (limited to 'lib/libsndio/aucat.c')
-rw-r--r--lib/libsndio/aucat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libsndio/aucat.c b/lib/libsndio/aucat.c
index 2edd216b615..fa1cd8f84d2 100644
--- a/lib/libsndio/aucat.c
+++ b/lib/libsndio/aucat.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aucat.c,v 1.74 2019/03/28 11:11:18 ratchov Exp $ */
+/* $OpenBSD: aucat.c,v 1.75 2019/06/28 05:35:34 deraadt Exp $ */
/*
* Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org>
*
@@ -282,7 +282,7 @@ bad_gen:
memcpy(tmp, path, path_len);
memcpy(tmp + path_len, TEMPL_SUFFIX, sizeof(TEMPL_SUFFIX));
fd = mkstemp(tmp);
- if (fd < 0) {
+ if (fd == -1) {
DPERROR(tmp);
goto done;
}