util/nvmutil: use xstrxlen for mac length

Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
Leah Rowe
2026-03-08 14:16:32 +00:00
parent 4a9aea629b
commit 9be83fa034
+1 -1
View File
@@ -606,7 +606,7 @@ parse_mac_string(void)
{
size_t mac_byte;
if (strlen(mac_str) != 17)
if (xstrxlen(mac_str, 18) != 17)
err(EINVAL, "MAC address is the wrong length");
memset(mac_buf, 0, sizeof(mac_buf));