Use bzero() to clear the whole ipfw_insn_icmp6 structure in fill_icmp6types(),

otherwise this command

ipfw add allow ipv6-icmp from any to 2002::1 icmp6types 1,2,128,129

turns into icmp6types 1,2,32,33,34,...94,95,128,129

PR:		102422 (part 1)
Submitted by:	Andrey V. Elsukov <bu7cher at yandex.ru>
MFC after:	5 days
This commit is contained in:
John Hay 2006-09-16 06:34:30 +00:00
parent f129892448
commit e7f2ec5364
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=162344

View file

@ -1206,7 +1206,7 @@ fill_icmp6types(ipfw_insn_icmp6 *cmd, char *av)
{
uint8_t type;
cmd->d[0] = 0;
bzero(cmd, sizeof(*cmd));
while (*av) {
if (*av == ',')
av++;