Fixed one more breakage introduced in 1.103 cleanup.

ICMP types were reported incorrectly:

# ipfw add allow icmp from any to any icmptypes 0,8

PR:		bin/29185
Submitted by:	Mike Durian <durian@boogie.com>
This commit is contained in:
Ruslan Ermilov 2001-08-06 13:03:38 +00:00
parent 2f6fec30cf
commit f47a6dce89

View File

@ -545,7 +545,8 @@ show_ipfw(struct ip_fw *chain)
for (i = 0; i < IP_FW_ICMPTYPES_DIM; ++i)
for (j = 0; j < sizeof(unsigned) * 8; ++j)
if (chain->fw_uar.fw_icmptypes[i] & (1 << j)) {
printf("%c%d", first ? ' ' : ',', i);
printf("%c%d", first ? ' ' : ',',
i * sizeof(unsigned) * 8 + j);
first = 0;
}
}