Hello,

Why is it not allowed to get more that 65536 ip6fw rules from the kernel
in the ip6fw.c:list() function?

Here is some lines from ip6fw.c:

        maxbytes = 65536 * sizeof *rules;
        while (bytes >= nalloc) {
                nalloc = nalloc * 2 + 200;
                bytes = nalloc;
                if ((rules = realloc(rules, bytes)) == NULL)
                        err(EX_OSERR, "realloc");
                i = getsockopt(s, IPPROTO_IPV6, IPV6_FW_GET, rules, &bytes);
                if ((i < 0 && errno != EINVAL) || nalloc > maxbytes)
                        err(EX_OSERR, "getsockopt(IPV6_FW_GET)");
        }


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message

Reply via email to