1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-10-18 02:19:39 +00:00

ipf: correct size limit in snprintf

Reported by:	GCC -Wsizeof-pointer-memaccess
Reviewed by:	zlei
Differential Revision:	https://reviews.freebsd.org/D45899
This commit is contained in:
Ryan Libby 2024-07-20 09:14:57 -07:00
parent eaa3d34b62
commit 90818083d7

View File

@ -449,7 +449,7 @@ yylex(void)
oc = c;
if (prior == YY_NUMBER && c == ':') {
snprintf(s, sizeof(s), "%d", priornum);
snprintf(s, sizeof(ipv6buf), "%d", priornum);
s += strlen(s);
}