diff options
| author | Leah Rowe <leah@libreboot.org> | 2026-03-09 17:44:48 +0000 |
|---|---|---|
| committer | Leah Rowe <leah@libreboot.org> | 2026-03-09 17:44:48 +0000 |
| commit | 646e3498932b1b6445d391e55e8a768bf3fe980c (patch) | |
| tree | 23140dc3f0ba30470b7dde073108e45b38fd8b84 | |
| parent | 85cc3071bbfebba9daf4a0ba6850e134a03821f1 (diff) | |
util/nvmutil: fix bsd build issue
urandom_fd is unavailable on bsd
Signed-off-by: Leah Rowe <leah@libreboot.org>
| -rw-r--r-- | util/nvmutil/nvmutil.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/util/nvmutil/nvmutil.c b/util/nvmutil/nvmutil.c index 8f422eb7..f3e6dd76 100644 --- a/util/nvmutil/nvmutil.c +++ b/util/nvmutil/nvmutil.c @@ -970,6 +970,7 @@ read_gbe_file_exact(int fd, void *buf, size_t len, } if (rval != -1) { +#ifndef NVMUTIL_ARC4RANDOM_BUF if (fd == urandom_fd) { /* * /dev/[u]random reads can still return @@ -986,7 +987,7 @@ read_gbe_file_exact(int fd, void *buf, size_t len, return rval; } } - +#endif err(ECANCELED, "Short %s, %zd bytes, on file: %s", op ? op : "read", rval, path); |
