summaryrefslogtreecommitdiff
path: root/util/nvmutil
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2026-03-16 15:36:10 +0000
committerLeah Rowe <leah@libreboot.org>2026-03-26 06:59:41 +0000
commitae43dc391f78fdd1b2c5c53254a6e148aa398192 (patch)
tree7c573e920022b22bdf09eeb737852f315a1ae1d5 /util/nvmutil
parentab806d25469591e71039a374151c7456df20afa8 (diff)
util/nvmutil: run-time CHAR_BIT test
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'util/nvmutil')
-rw-r--r--util/nvmutil/nvmutil.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/util/nvmutil/nvmutil.c b/util/nvmutil/nvmutil.c
index 1dd07e9f..59ceb2c5 100644
--- a/util/nvmutil/nvmutil.c
+++ b/util/nvmutil/nvmutil.c
@@ -719,6 +719,9 @@ main(int argc, char *argv[])
if (argc < 3)
usage();
+ if (CHAR_BIT != 8)
+ err(EINVAL, "Unsupported char size");
+
fname = argv[1];
#ifdef NVMUTIL_UNVEIL