diff options
| author | Leah Rowe <leah@libreboot.org> | 2026-03-24 22:27:04 +0000 |
|---|---|---|
| committer | Leah Rowe <leah@libreboot.org> | 2026-03-24 22:44:27 +0000 |
| commit | 1ed2ca6b6977a6f8edea309d10bee0dbeb315d71 (patch) | |
| tree | bb2bb13193dc1e971a783cb974cdcd38c4f941e6 /util/libreboot-utils/lib/file.c | |
| parent | 4fc4946f3c257bb5228df0a8393316b1119c6712 (diff) | |
util/libreboot-utils: rename err() to b0rk()
it behaves a bit differently than err(), so it's
not good to confuse readers
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'util/libreboot-utils/lib/file.c')
| -rw-r--r-- | util/libreboot-utils/lib/file.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/util/libreboot-utils/lib/file.c b/util/libreboot-utils/lib/file.c index 4a12cca7..46d5e016 100644 --- a/util/libreboot-utils/lib/file.c +++ b/util/libreboot-utils/lib/file.c @@ -96,16 +96,16 @@ void xopen(int *fd_ptr, const char *path, int flags, struct stat *st) { if ((*fd_ptr = open(path, flags)) < 0) - err(errno, "%s", path); + err_no_cleanup(errno, "%s", path); if (fstat(*fd_ptr, st) < 0) - err(errno, "%s: stat", path); + err_no_cleanup(errno, "%s: stat", path); if (!S_ISREG(st->st_mode)) - err(errno, "%s: not a regular file", path); + err_no_cleanup(errno, "%s: not a regular file", path); if (lseek_on_eintr(*fd_ptr, 0, SEEK_CUR, 1, 1) == (off_t)-1) - err(errno, "%s: file not seekable", path); + err_no_cleanup(errno, "%s: file not seekable", path); } /* fsync() the directory of a file, |
