util/nvmutil: add assert for off_t

Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
Leah Rowe
2026-03-10 06:30:52 +00:00
parent 6ad7eaef32
commit 83f3a059b9
+7
View File
@@ -54,6 +54,13 @@ typedef char static_assert_uint8_is_1[(sizeof(uint8_t) == 1) ? 1 : -1];
typedef char static_assert_uint16_is_2[(sizeof(uint16_t) == 2) ? 1 : -1];
typedef char static_assert_uint32_is_4[(sizeof(uint32_t) == 4) ? 1 : -1];
/*
* We set _FILE_OFFSET_BITS 64, but we only handle
* files that are 128KB in size at a maximum, so we
* realistically only need 32-bit at a minimum.
*/
typedef char static_assert_off_t_is_64[(sizeof(off_t) >= 4) ? 1 : -1];
/*
* The BSD versions that could realistically build
* nvmutil almost certainly have arc4random (first