From 63984a4a6abb7a65098f27196fcb6395fc0ada22 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Sat, 28 Mar 2026 07:30:55 +0000 Subject: libreboot-utils: much stricter close() handling remove close_warn and close_no_err make close_on_eintr a void, and abort on error instead of returning -1. a failed file closure is a world-ending event. burn accordingly. Signed-off-by: Leah Rowe --- util/libreboot-utils/lib/rand.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'util/libreboot-utils/lib/rand.c') diff --git a/util/libreboot-utils/lib/rand.c b/util/libreboot-utils/lib/rand.c index 3ca19d0c..99da713c 100644 --- a/util/libreboot-utils/lib/rand.c +++ b/util/libreboot-utils/lib/rand.c @@ -169,7 +169,7 @@ retry_rand: #if defined(USE_URANDOM) && \ ((USE_URANDOM) > 0) - close_no_err(&fd); + close_on_eintr(&fd); #endif goto out; #endif @@ -179,7 +179,7 @@ out: err: #if defined(USE_URANDOM) && \ ((USE_URANDOM) > 0) - close_no_err(&fd); + close_on_eintr(&fd); #endif err_exit(ECANCELED, "Randomisation failure, possibly unsupported in your kernel"); -- cgit v1.2.1