lbutils hexdump: reduce width on smaller integers

showing the size for 64-bit high integers seems silly

Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
Leah Rowe
2026-03-29 14:26:56 +01:00
parent ac04a5f50a
commit e4016eb32c
+4 -1
View File
@@ -80,7 +80,10 @@ spew_hex(const void *data, size_t len)
for (i = 0; i < len; i += 16) {
printf("%0*zx ", sizeof(size_t) * 2, i);
if (len <= 4294967296) /* below 4GB */
printf("%08zx ", i);
else
printf("%0*zx ", sizeof(size_t) * 2, i);
for (j = 0; j < 16; j++) {