summaryrefslogtreecommitdiff
path: root/util/libreboot-utils
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2026-04-03 03:11:27 +0100
committerLeah Rowe <leah@libreboot.org>2026-04-10 22:59:08 +0100
commit7619bfed6569579822d326678f65cbdd704e3405 (patch)
tree7e9cb787de58d33335403320180c36cf9cbe85ca /util/libreboot-utils
parent9dab2ffa297a81d4064385bc5813bf870bdacf47 (diff)
lbutils/mkhtemp: correct return value checkHEADmaster
check if above or equal to zero, except where counterindicated. this is the usual way on unix, where a command returns -1 on error, or above/equal to zero on success. Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'util/libreboot-utils')
-rw-r--r--util/libreboot-utils/lib/mkhtemp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/libreboot-utils/lib/mkhtemp.c b/util/libreboot-utils/lib/mkhtemp.c
index d9411104..da44a7e2 100644
--- a/util/libreboot-utils/lib/mkhtemp.c
+++ b/util/libreboot-utils/lib/mkhtemp.c
@@ -547,7 +547,7 @@ mkhtemp_try_create(int dirfd,
/* try O_TMPFILE fast path */
if (mkhtemp_tmpfile_linux(dirfd,
st_dir_first, fname_copy,
- p, xc, fd, st) == 0) {
+ p, xc, fd, st) >= 0) {
errno = saved_errno;
rval = 1;