The branch main has been updated by cy:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=701301511f0ca044fc71470ed7842cd2c6fee001

commit 701301511f0ca044fc71470ed7842cd2c6fee001
Author:     Cy Schubert <c...@freebsd.org>
AuthorDate: 2022-01-04 02:42:49 +0000
Commit:     Cy Schubert <c...@freebsd.org>
CommitDate: 2022-01-04 02:46:49 +0000

    ipfilter module: Style(9) requires a space after return
    
    Reported by:    jrtc27
    Fixes:          8c82b37461fa4e60276639df214100fbf559ea6e
    MFC after:      1 month
---
 sys/netpfil/ipfilter/netinet/fil.c            | 664 +++++++++++++-------------
 sys/netpfil/ipfilter/netinet/ip_auth.c        |  70 +--
 sys/netpfil/ipfilter/netinet/ip_dns_pxy.c     |  44 +-
 sys/netpfil/ipfilter/netinet/ip_dstlist.c     |  92 ++--
 sys/netpfil/ipfilter/netinet/ip_fil_freebsd.c | 146 +++---
 sys/netpfil/ipfilter/netinet/ip_frag.c        |  84 ++--
 sys/netpfil/ipfilter/netinet/ip_ftp_pxy.c     | 190 ++++----
 sys/netpfil/ipfilter/netinet/ip_htable.c      | 120 ++---
 sys/netpfil/ipfilter/netinet/ip_ipsec_pxy.c   |  40 +-
 sys/netpfil/ipfilter/netinet/ip_irc_pxy.c     |  64 +--
 sys/netpfil/ipfilter/netinet/ip_log.c         |  64 +--
 sys/netpfil/ipfilter/netinet/ip_lookup.c      |  66 +--
 sys/netpfil/ipfilter/netinet/ip_nat.c         | 388 +++++++--------
 sys/netpfil/ipfilter/netinet/ip_nat6.c        | 190 ++++----
 sys/netpfil/ipfilter/netinet/ip_netbios_pxy.c |   4 +-
 sys/netpfil/ipfilter/netinet/ip_pool.c        | 118 ++---
 sys/netpfil/ipfilter/netinet/ip_pptp_pxy.c    |  26 +-
 sys/netpfil/ipfilter/netinet/ip_proxy.c       |  96 ++--
 sys/netpfil/ipfilter/netinet/ip_raudio_pxy.c  |  28 +-
 sys/netpfil/ipfilter/netinet/ip_rcmd_pxy.c    |  30 +-
 sys/netpfil/ipfilter/netinet/ip_rpcb_pxy.c    | 176 +++----
 sys/netpfil/ipfilter/netinet/ip_rules.c       |  28 +-
 sys/netpfil/ipfilter/netinet/ip_scan.c        |  58 +--
 sys/netpfil/ipfilter/netinet/ip_state.c       | 258 +++++-----
 sys/netpfil/ipfilter/netinet/ip_sync.c        |  60 +--
 sys/netpfil/ipfilter/netinet/ip_tftp_pxy.c    |  36 +-
 sys/netpfil/ipfilter/netinet/ipf_rb.h         |   6 +-
 sys/netpfil/ipfilter/netinet/mlfk_ipl.c       |  52 +-
 sys/netpfil/ipfilter/netinet/radix_ipf.c      |  60 +--
 29 files changed, 1629 insertions(+), 1629 deletions(-)

diff --git a/sys/netpfil/ipfilter/netinet/fil.c 
b/sys/netpfil/ipfilter/netinet/fil.c
index 3b135ebf1d3d..9db403709b00 100644
--- a/sys/netpfil/ipfilter/netinet/fil.c
+++ b/sys/netpfil/ipfilter/netinet/fil.c
@@ -624,12 +624,12 @@ ipf_pr_ipv6exthdr(fr_info_t *fin, int multiple, int proto)
        if ((fin->fin_dlen - 8) < 0) {
                fin->fin_flx |= FI_SHORT;
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_ext_short);
-               return(NULL);
+               return (NULL);
        }
 
        if (ipf_pr_pullup(fin, 8) == -1) {
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_ext_pullup);
-               return(NULL);
+               return (NULL);
        }
 
        hdr = fin->fin_dp;
@@ -647,7 +647,7 @@ ipf_pr_ipv6exthdr(fr_info_t *fin, int multiple, int proto)
                fin->fin_flx |= FI_BAD;
                DT3(ipf_fi_bad_pr_ipv6exthdr_len, fr_info_t *, fin, u_short, 
shift, u_short, fin->fin_dlen);
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_ext_hlen);
-               return(NULL);
+               return (NULL);
        }
 
        fin->fin_dp = (char *)fin->fin_dp + shift;
@@ -659,7 +659,7 @@ ipf_pr_ipv6exthdr(fr_info_t *fin, int multiple, int proto)
         * end result until after it has been defragmented.
         */
        if (fin->fin_flx & FI_FRAG)
-               return(hdr);
+               return (hdr);
 
        for (i = 0; ip6exthdr[i].ol_bit != 0; i++)
                if (ip6exthdr[i].ol_val == proto) {
@@ -675,7 +675,7 @@ ipf_pr_ipv6exthdr(fr_info_t *fin, int multiple, int proto)
                        break;
                }
 
-       return(hdr);
+       return (hdr);
 }
 
 
@@ -694,8 +694,8 @@ ipf_pr_hopopts6(fr_info_t *fin)
 
        hdr = ipf_pr_ipv6exthdr(fin, 0, IPPROTO_HOPOPTS);
        if (hdr == NULL)
-               return(IPPROTO_NONE);
-       return(hdr->ip6e_nxt);
+               return (IPPROTO_NONE);
+       return (hdr->ip6e_nxt);
 }
 
 
@@ -714,8 +714,8 @@ ipf_pr_mobility6(fr_info_t *fin)
 
        hdr = ipf_pr_ipv6exthdr(fin, 0, IPPROTO_MOBILITY);
        if (hdr == NULL)
-               return(IPPROTO_NONE);
-       return(hdr->ip6e_nxt);
+               return (IPPROTO_NONE);
+       return (hdr->ip6e_nxt);
 }
 
 
@@ -734,7 +734,7 @@ ipf_pr_routing6(fr_info_t *fin)
 
        hdr = (struct ip6_routing *)ipf_pr_ipv6exthdr(fin, 0, IPPROTO_ROUTING);
        if (hdr == NULL)
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
 
        switch (hdr->ip6r_type)
        {
@@ -749,7 +749,7 @@ ipf_pr_routing6(fr_info_t *fin)
                        fin->fin_flx |= FI_BAD;
                        DT1(ipf_fi_bad_routing6, fr_info_t *, fin);
                        LBUMPD(ipf_stats[fin->fin_out], fr_v6_rh_bad);
-                       return(IPPROTO_NONE);
+                       return (IPPROTO_NONE);
                }
                break;
 
@@ -757,7 +757,7 @@ ipf_pr_routing6(fr_info_t *fin)
                break;
        }
 
-       return(hdr->ip6r_nxt);
+       return (hdr->ip6r_nxt);
 }
 
 
@@ -801,7 +801,7 @@ ipf_pr_fragment6(fr_info_t *fin)
        frag = (struct ip6_frag *)ipf_pr_ipv6exthdr(fin, 0, IPPROTO_FRAGMENT);
        if (frag == NULL) {
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_frag_bad);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
 
        if ((frag->ip6f_offlg & IP6F_MORE_FRAG) != 0) {
@@ -836,7 +836,7 @@ ipf_pr_fragment6(fr_info_t *fin)
         * this effectively disables the fragment cache for > 1 protocol at a
         * time.
         */
-       return(frag->ip6f_nxt);
+       return (frag->ip6f_nxt);
 }
 
 
@@ -857,9 +857,9 @@ ipf_pr_dstopts6(fr_info_t *fin)
        hdr = ipf_pr_ipv6exthdr(fin, 0, IPPROTO_DSTOPTS);
        if (hdr == NULL) {
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_dst_bad);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
-       return(hdr->ip6e_nxt);
+       return (hdr->ip6e_nxt);
 }
 
 
@@ -1043,7 +1043,7 @@ ipf_pr_ah6(fr_info_t *fin)
                ipf_main_softc_t *softc = fin->fin_main_soft;
 
                LBUMPD(ipf_stats[fin->fin_out], fr_v6_ah_bad);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
 
        ipf_pr_short6(fin, sizeof(*ah));
@@ -1052,7 +1052,7 @@ ipf_pr_ah6(fr_info_t *fin)
         * No need for another pullup, ipf_pr_ipv6exthdr() will pullup
         * enough data to satisfy ah_next (the very first one.)
         */
-       return(ah->ah_next);
+       return (ah->ah_next);
 }
 
 
@@ -1115,7 +1115,7 @@ ipf_pr_pullup(fr_info_t *fin, int plen)
                        if (ipf_pullup(fin->fin_m, fin, plen) == NULL) {
                                DT(ipf_pullup_fail);
                                LBUMP(ipf_stats[fin->fin_out].fr_pull[1]);
-                               return(-1);
+                               return (-1);
                        }
                        LBUMP(ipf_stats[fin->fin_out].fr_pull[0]);
 #else
@@ -1127,11 +1127,11 @@ ipf_pr_pullup(fr_info_t *fin, int plen)
                        *fin->fin_mp = NULL;
                        fin->fin_m = NULL;
                        fin->fin_ip = NULL;
-                       return(-1);
+                       return (-1);
 #endif
                }
        }
-       return(0);
+       return (0);
 }
 
 
@@ -1302,12 +1302,12 @@ ipf_pr_tcpcommon(fr_info_t *fin)
        fin->fin_flx |= FI_TCPUDP;
        if (fin->fin_off != 0) {
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_frag);
-               return(0);
+               return (0);
        }
 
        if (ipf_pr_pullup(fin, sizeof(*tcp)) == -1) {
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_pullup);
-               return(-1);
+               return (-1);
        }
 
        tcp = fin->fin_dp;
@@ -1318,7 +1318,7 @@ ipf_pr_tcpcommon(fr_info_t *fin)
 
        if ((fin->fin_flx & FI_SHORT) != 0) {
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_short);
-               return(1);
+               return (1);
        }
 
        /*
@@ -1330,7 +1330,7 @@ ipf_pr_tcpcommon(fr_info_t *fin)
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_small);
                fin->fin_flx |= FI_BAD;
                DT3(ipf_fi_bad_tlen, fr_info_t, fin, u_int, tlen, u_int, 
sizeof(tcphdr_t));
-               return(1);
+               return (1);
        }
 
        flags = tcp->th_flags;
@@ -1396,7 +1396,7 @@ ipf_pr_tcpcommon(fr_info_t *fin)
        }
        if (fin->fin_flx & FI_BAD) {
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_bad_flags);
-               return(1);
+               return (1);
        }
 
        /*
@@ -1408,12 +1408,12 @@ ipf_pr_tcpcommon(fr_info_t *fin)
         * then that might add some weight to adding this...
         */
        if (tlen == sizeof(tcphdr_t)) {
-               return(0);
+               return (0);
        }
 
        if (ipf_pr_pullup(fin, tlen) == -1) {
                LBUMPD(ipf_stats[fin->fin_out], fr_tcp_pullup);
-               return(-1);
+               return (-1);
        }
 
 #if 0
@@ -1455,7 +1455,7 @@ ipf_pr_tcpcommon(fr_info_t *fin)
        }
 #endif /* 0 */
 
-       return(0);
+       return (0);
 }
 
 
@@ -1481,7 +1481,7 @@ ipf_pr_udpcommon(fr_info_t *fin)
 
                        fin->fin_flx |= FI_SHORT;
                        LBUMPD(ipf_stats[fin->fin_out], fr_udp_pullup);
-                       return(1);
+                       return (1);
                }
 
                udp = fin->fin_dp;
@@ -1490,7 +1490,7 @@ ipf_pr_udpcommon(fr_info_t *fin)
                fin->fin_dport = ntohs(udp->uh_dport);
        }
 
-       return(0);
+       return (0);
 }
 
 
@@ -1579,13 +1579,13 @@ ipf_pr_ah(fr_info_t *fin)
 
        if (((fin->fin_flx & FI_SHORT) != 0) || (fin->fin_off != 0)) {
                LBUMPD(ipf_stats[fin->fin_out], fr_v4_ah_bad);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
 
        if (ipf_pr_pullup(fin, sizeof(*ah)) == -1) {
                DT(fr_v4_ah_pullup_1);
                LBUMP(ipf_stats[fin->fin_out].fr_v4_ah_pullup);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
 
        ah = (authhdr_t *)fin->fin_dp;
@@ -1595,7 +1595,7 @@ ipf_pr_ah(fr_info_t *fin)
        if (ipf_pr_pullup(fin, len) == -1) {
                DT(fr_v4_ah_pullup_2);
                LBUMP(ipf_stats[fin->fin_out].fr_v4_ah_pullup);
-               return(IPPROTO_NONE);
+               return (IPPROTO_NONE);
        }
 
        /*
@@ -1604,7 +1604,7 @@ ipf_pr_ah(fr_info_t *fin)
         */
        fin->fin_dp = (char *)fin->fin_dp + len;
        fin->fin_dlen -= len;
-       return(ah->ah_next);
+       return (ah->ah_next);
 }
 
 
@@ -1879,7 +1879,7 @@ ipf_checkripso(u_char *s)
                m--;
        }
 
-       return(secmsk << 16) | auth;
+       return (secmsk << 16) | auth;
 }
 
 
@@ -1911,7 +1911,7 @@ ipf_checkcipso(fr_info_t *fin, u_char *s, int ol)
                LBUMPD(ipf_stats[fin->fin_out], fr_v4_cipso_bad);
                fin->fin_flx |= FI_BAD;
                DT2(ipf_fi_bad_checkcipso_ol, fr_info_t *, fin, u_int, ol);
-               return(0);
+               return (0);
        }
 
        fi = &fin->fin_fi;
@@ -1929,7 +1929,7 @@ ipf_checkcipso(fr_info_t *fin, u_char *s, int ol)
                        LBUMPD(ipf_stats[fin->fin_out], fr_v4_cipso_tlen);
                        fin->fin_flx |= FI_BAD;
                        DT2(ipf_fi_bad_checkcipso_tlen, fr_info_t *, fin, 
u_int, tlen);
-                       return(0);
+                       return (0);
                }
 
                sensitivity = 0;
@@ -1981,7 +1981,7 @@ ipf_checkcipso(fr_info_t *fin, u_char *s, int ol)
                        fi->fi_sensitivity = sensitivity;
        }
 
-       return(doi);
+       return (doi);
 }
 
 
@@ -2027,9 +2027,9 @@ ipf_makefrip(int hlen, ip_t *ip, fr_info_t *fin)
        }
        if (fin->fin_ip == NULL) {
                LBUMP(ipf_stats[fin->fin_out].fr_ip_freed);
-               return(-1);
+               return (-1);
        }
-       return(0);
+       return (0);
 }
 
 
@@ -2094,7 +2094,7 @@ ipf_portcheck(frpcmp_t *frp, u_32_t pop)
        default :
                break;
        }
-       return(err);
+       return (err);
 }
 
 
@@ -2135,7 +2135,7 @@ ipf_tcpudpchk(fr_ip_t *fi, frtuc_t *ft)
         */
        if (err && (fi->fi_p == IPPROTO_TCP)) {
                if (fi->fi_flx & FI_SHORT)
-                       return(!(ft->ftu_tcpf | ft->ftu_tcpfm));
+                       return (!(ft->ftu_tcpf | ft->ftu_tcpfm));
                /*
                 * Match the flags ?  If not, abort this match.
                 */
@@ -2146,7 +2146,7 @@ ipf_tcpudpchk(fr_ip_t *fi, frtuc_t *ft)
                        err = 0;
                }
        }
-       return(err);
+       return (err);
 }
 
 
@@ -2184,7 +2184,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
        FR_DEBUG(("0. %#08x & %#08x != %#08x\n",
                   ntohl(*lip), ntohl(*lm), ntohl(*ld)));
        if (i)
-               return(1);
+               return (1);
 
        /*
         * Next 32 bits is a constructed bitmask indicating which IP options
@@ -2195,7 +2195,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
        FR_DEBUG(("1. %#08x & %#08x != %#08x\n",
                   ntohl(*lip), ntohl(*lm), ntohl(*ld)));
        if (i != 0)
-               return(1);
+               return (1);
 
        lip++, lm++, ld++;
        /*
@@ -2208,7 +2208,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
                i = (*fr->fr_srcfunc)(fin->fin_main_soft, fr->fr_srcptr,
                                      fi->fi_v, lip, fin->fin_plen);
                if (i == -1)
-                       return(1);
+                       return (1);
                lip += 3;
                lm += 3;
                ld += 3;
@@ -2237,7 +2237,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
        }
        i ^= (fr->fr_flags & FR_NOTSRCIP) >> 6;
        if (i != 0)
-               return(1);
+               return (1);
 
        /*
         * Check the destination address.
@@ -2247,7 +2247,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
                i = (*fr->fr_dstfunc)(fin->fin_main_soft, fr->fr_dstptr,
                                      fi->fi_v, lip, fin->fin_plen);
                if (i == -1)
-                       return(1);
+                       return (1);
                lip += 3;
                lm += 3;
                ld += 3;
@@ -2276,7 +2276,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
        }
        i ^= (fr->fr_flags & FR_NOTDSTIP) >> 7;
        if (i != 0)
-               return(1);
+               return (1);
        /*
         * IP addresses matched.  The next 32bits contains:
         * mast of old IP header security & authentication bits.
@@ -2319,7 +2319,7 @@ ipf_check_ipf(fr_info_t *fin, frentry_t *fr, int portcmp)
                        }
                }
        }
-       return(i);
+       return (i);
 }
 
 
@@ -2351,7 +2351,7 @@ ipf_scanlist(fr_info_t *fin, u_32_t pass)
         * Do not allow nesting deeper than 16 levels.
         */
        if (fin->fin_depth >= 16)
-               return(pass);
+               return (pass);
 
        fr = fin->fin_fr;
 
@@ -2359,7 +2359,7 @@ ipf_scanlist(fr_info_t *fin, u_32_t pass)
        * If there are no rules in this list, return now.
         */
        if (fr == NULL)
-               return(pass);
+               return (pass);
 
        skip = 0;
        portcmp = 0;
@@ -2576,7 +2576,7 @@ ipf_scanlist(fr_info_t *fin, u_32_t pass)
                }
        }
        fin->fin_depth--;
-       return(pass);
+       return (pass);
 }
 
 
@@ -2616,7 +2616,7 @@ ipf_acctpkt(fr_info_t *fin, u_32_t *passp)
                bcopy(group, fin->fin_group, FR_GROUPLEN);
                fin->fin_rule = rulen;
        }
-       return(NULL);
+       return (NULL);
 }
 
 
@@ -2719,7 +2719,7 @@ ipf_firewall(fr_info_t *fin, u_32_t *passp)
        fr = fin->fin_fr;
        *passp = pass;
 
-       return(fr);
+       return (fr);
 }
 
 
@@ -2786,14 +2786,14 @@ ipf_check(void *ctx, ip_t *ip, int hlen, struct ifnet 
*ifp, int out
 
 #  ifdef __sparc
        if ((u_int)ip & 0x3)
-               return(2);
+               return (2);
 #  endif
 # else
        SPL_INT(s);
 # endif
 
        if (softc->ipf_running <= 0) {
-               return(0);
+               return (0);
        }
 
        bzero((char *)fin, sizeof(*fin));
@@ -3182,9 +3182,9 @@ finished:
 
 #ifdef _KERNEL
        if (FR_ISPASS(pass))
-               return(0);
+               return (0);
        LBUMP(ipf_stats[out].fr_blocked[fin->fin_reason]);
-       return(fin->fin_error);
+       return (fin->fin_error);
 #else /* _KERNEL */
        if (*mp != NULL)
                (*mp)->mb_ifp = fin->fin_ifp;
@@ -3192,33 +3192,33 @@ finished:
        FR_VERBOSE(("fin_flx %#x pass %#x ", fin->fin_flx, pass));
        /*if ((pass & FR_CMDMASK) == (softc->ipf_pass & FR_CMDMASK))*/
                if ((pass & FR_NOMATCH) != 0)
-                       return(1);
+                       return (1);
 
        if ((pass & FR_RETMASK) != 0)
                switch (pass & FR_RETMASK)
                {
                case FR_RETRST :
-                       return(3);
+                       return (3);
                case FR_RETICMP :
-                       return(4);
+                       return (4);
                case FR_FAKEICMP :
-                       return(5);
+                       return (5);
                }
 
        switch (pass & FR_CMDMASK)
        {
        case FR_PASS :
-               return(0);
+               return (0);
        case FR_BLOCK :
-               return(-1);
+               return (-1);
        case FR_AUTH :
-               return(-2);
+               return (-2);
        case FR_ACCOUNT :
-               return(-3);
+               return (-3);
        case FR_PREAUTH :
-               return(-4);
+               return (-4);
        }
-       return(2);
+       return (2);
 #endif /* _KERNEL */
 }
 
@@ -3277,7 +3277,7 @@ logit:
                *passp = pass;
        }
 
-       return(fin->fin_fr);
+       return (fin->fin_fr);
 }
 #endif /* IPFILTER_LOG */
 
@@ -3309,7 +3309,7 @@ ipf_cksum(u_short *addr, int len)
         */
        sum = (sum >> 16) + (sum & 0xffff);     /* add hi 16 to low 16 */
        sum += (sum >> 16);                     /* add carry */
-       return(u_short)(~sum);
+       return (u_short)(~sum);
 }
 
 
@@ -3372,9 +3372,9 @@ fr_cksum(fr_info_t *fin, ip_t *ip, int l4proto, void 
*l4hdr)
                ip6 = (ip6_t *)ip;
                off = ((caddr_t)ip6 - m->m_data) + sizeof(struct ip6_hdr);
                int len = ntohs(ip6->ip6_plen) - (off - sizeof(*ip6));
-               return(ipf_pcksum6(m, ip6, off, len));
+               return (ipf_pcksum6(m, ip6, off, len));
        } else {
-               return(0xffff);
+               return (0xffff);
        }
 #endif
 
@@ -3408,7 +3408,7 @@ fr_cksum(fr_info_t *fin, ip_t *ip, int l4proto, void 
*l4hdr)
        sum2 = ipf_pcksum(fin, off, sum);
        if (csump != NULL)
                *csump = sumsave;
-       return(sum2);
+       return (sum2);
 }
 
 
@@ -3445,7 +3445,7 @@ ipf_findgroup(ipf_main_softc_t *softc, char *group, 
minor_t unit, int set,
        }
        if (fgpp != NULL)
                *fgpp = fgp;
-       return(fg);
+       return (fg);
 }
 
 
@@ -3472,10 +3472,10 @@ ipf_group_add(ipf_main_softc_t *softc, char *group, 
void *head, u_32_t flags,
        u_32_t gflags;
 
        if (group == NULL)
-               return(NULL);
+               return (NULL);
 
        if (unit == IPL_LOGIPF && *group == '\0')
-               return(NULL);
+               return (NULL);
 
        fgp = NULL;
        gflags = flags & FR_INOUT;
@@ -3487,9 +3487,9 @@ ipf_group_add(ipf_main_softc_t *softc, char *group, void 
*head, u_32_t flags,
                if (fg->fg_flags == 0)
                        fg->fg_flags = gflags;
                else if (gflags != fg->fg_flags)
-                       return(NULL);
+                       return (NULL);
                fg->fg_ref++;
-               return(fg);
+               return (fg);
        }
 
        KMALLOC(fg, frgroup_t *);
@@ -3503,7 +3503,7 @@ ipf_group_add(ipf_main_softc_t *softc, char *group, void 
*head, u_32_t flags,
                fg->fg_set = &softc->ipf_groups[unit][set];
                *fgp = fg;
        }
-       return(fg);
+       return (fg);
 }
 
 
@@ -3570,7 +3570,7 @@ ipf_group_flush(ipf_main_softc_t *softc, frgroup_t *group)
 
        (void) ipf_flushlist(softc, &gone, &group->fg_start);
 
-       return(gone);
+       return (gone);
 }
 
 
@@ -3594,12 +3594,12 @@ ipf_getrulen(ipf_main_softc_t *softc, int unit, char 
*group, u_32_t n)
 
        fg = ipf_findgroup(softc, group, unit, softc->ipf_active, NULL);
        if (fg == NULL)
-               return(NULL);
+               return (NULL);
        for (fr = fg->fg_start; fr && n; fr = fr->fr_next, n--)
                ;
        if (n != 0)
-               return(NULL);
-       return(fr);
+               return (NULL);
+       return (fr);
 }
 
 
@@ -3657,7 +3657,7 @@ ipf_flushlist(ipf_main_softc_t *softc, int *nfreedp, 
frentry_t **listp)
                        freed++;
        }
        *nfreedp += freed;
-       return(freed);
+       return (freed);
 }
 
 
@@ -3703,7 +3703,7 @@ ipf_flush(ipf_main_softc_t *softc, minor_t unit, int 
flags)
                if (tmp >= 0)
                        flushed += tmp;
        }
-       return(flushed);
+       return (flushed);
 }
 
 
@@ -3753,7 +3753,7 @@ ipf_flush_groups(ipf_main_softc_t *softc, frgroup_t 
**grhead, int flags)
                if (removed == 0)
                        fgp = &fg->fg_next;
        }
-       return(flushed);
+       return (flushed);
 }
 
 
@@ -3781,7 +3781,7 @@ memstr(const char *src, char *dst, size_t slen, size_t 
dlen)
                dst++;
                dlen--;
        }
-       return(s);
+       return (s);
 }
 /* ------------------------------------------------------------------------ */
 /* Function:    ipf_fixskip                                                 */
@@ -3844,8 +3844,8 @@ count4bits(u_32_t ip)
                        ipn++;
        }
        if (ipn == ip)
-               return(cnt);
-       return(-1);
+               return (cnt);
+       return (-1);
 }
 
 
@@ -3872,7 +3872,7 @@ count6bits(u_32_t *msk)
                                if (j & 0x80000000)
                                        i++;
                }
-       return(i);
+       return (i);
 }
 # endif
 #endif /* _KERNEL */
@@ -3981,7 +3981,7 @@ ipf_synclist(ipf_main_softc_t *softc, frentry_t *fr, void 
*ifp)
                                                           &fr->fr_dstfunc);
                }
        }
-       return(0);
+       return (0);
 
 unwind:
        for (frt = start; frt != fr; fr = fr->fr_next) {
@@ -3994,7 +3994,7 @@ unwind:
                                ipf_lookup_deref(softc, frt->fr_dsttype,
                                                 frt->fr_dstptr);
        }
-       return(error);
+       return (error);
 }
 
 
@@ -4035,7 +4035,7 @@ ipf_sync(ipf_main_softc_t *softc, void *ifp)
        }
        RWLOCK_EXIT(&softc->ipf_mutex);
 
-       return(0);
+       return (0);
 }
 
 
@@ -4064,7 +4064,7 @@ copyinptr(ipf_main_softc_t *softc, void *src, void *dst, 
size_t size)
 #if SOLARIS
        error = COPYIN(src, &ca, sizeof(ca));
        if (error != 0)
-               return(error);
+               return (error);
 #else
        bcopy(src, (caddr_t)&ca, sizeof(ca));
 #endif
@@ -4073,7 +4073,7 @@ copyinptr(ipf_main_softc_t *softc, void *src, void *dst, 
size_t size)
                IPFERROR(3);
                error = EFAULT;
        }
-       return(error);
+       return (error);
 }
 
 
@@ -4100,7 +4100,7 @@ copyoutptr(ipf_main_softc_t *softc, void *src, void *dst, 
size_t size)
                IPFERROR(4);
                error = EFAULT;
        }
-       return(error);
+       return (error);
 }
 
 
@@ -4120,12 +4120,12 @@ ipf_lock(caddr_t data, int *lockp)
 
        err = BCOPYIN(data, &arg, sizeof(arg));
        if (err != 0)
-               return(EFAULT);
+               return (EFAULT);
        err = BCOPYOUT(lockp, data, sizeof(*lockp));
        if (err != 0)
-               return(EFAULT);
+               return (EFAULT);
        *lockp = arg;
-       return(0);
+       return (0);
 }
 
 
@@ -4275,9 +4275,9 @@ ipf_matchicmpqueryreply(int v, icmpinfo_t *ic, icmphdr_t 
*icmp, int rev)
                if ((!rev && (icmp->icmp_type == ictype)) ||
                    (rev && (icmpreplytype4[ictype] == icmp->icmp_type))) {
                        if (icmp->icmp_type != ICMP_ECHOREPLY)
-                               return(1);
+                               return (1);
                        if (icmp->icmp_id == ic->ici_id)
-                               return(1);
+                               return (1);
                }
        }
 #ifdef USE_INET6
@@ -4285,13 +4285,13 @@ ipf_matchicmpqueryreply(int v, icmpinfo_t *ic, 
icmphdr_t *icmp, int rev)
                if ((!rev && (icmp->icmp_type == ictype)) ||
                    (rev && (icmpreplytype6[ictype] == icmp->icmp_type))) {
                        if (icmp->icmp_type != ICMP6_ECHO_REPLY)
-                               return(1);
+                               return (1);
                        if (icmp->icmp_id == ic->ici_id)
-                               return(1);
+                               return (1);
                }
        }
 #endif
-       return(0);
+       return (0);
 }
 
 
@@ -4332,14 +4332,14 @@ ipf_rule_compare(frentry_t *fr1, frentry_t *fr2)
        int i;
 
        if (fr1->fr_cksum != fr2->fr_cksum)
-               return(1);
+               return (1);
        if (fr1->fr_size != fr2->fr_size)
-               return(2);
+               return (2);
        if (fr1->fr_dsize != fr2->fr_dsize)
-               return(3);
+               return (3);
        if (bcmp((char *)&fr1->fr_func, (char *)&fr2->fr_func, FR_CMPSIZ)
            != 0)
-               return(4);
+               return (4);
        /*
         * XXX: There is still a bug here as different rules with the
         *      the same interfaces but in a different order will compare
@@ -4357,22 +4357,22 @@ ipf_rule_compare(frentry_t *fr1, frentry_t *fr2)
                 *      referenced by the same rule doesn't work anyway.
                 */
                if (IPF_IFNAMES_DIFFERENT(fr_ifnames[i]))
-                       return(5);
+                       return (5);
        }
 
        if (IPF_FRDEST_DIFFERENT(fr_tif))
-               return(6);
+               return (6);
        if (IPF_FRDEST_DIFFERENT(fr_rif))
-               return(7);
+               return (7);
        if (IPF_FRDEST_DIFFERENT(fr_dif))
-               return(8);
+               return (8);
        if (!fr1->fr_data && !fr2->fr_data)
-               return(0);      /* move along, nothing to see here */
+               return (0);     /* move along, nothing to see here */
        if (fr1->fr_data && fr2->fr_data) {
                if (bcmp(fr1->fr_caddr, fr2->fr_caddr, fr1->fr_dsize) == 0)
-                       return(0);      /* same */
+                       return (0);     /* same */
        }
-       return(9);
+       return (9);
 }
 
 
@@ -4416,23 +4416,23 @@ frrequest(ipf_main_softc_t *softc, int unit, ioctlcmd_t 
req, caddr_t data,
                bzero(fp, sizeof(frd));
                error = ipf_inobj(softc, data, NULL, fp, IPFOBJ_FRENTRY);
                if (error) {
-                       return(error);
+                       return (error);
                }
                if ((fp->fr_type & FR_T_BUILTIN) != 0) {
                        IPFERROR(6);
-                       return(EINVAL);
+                       return (EINVAL);
                }
                KMALLOCS(f, frentry_t *, fp->fr_size);
                if (f == NULL) {
                        IPFERROR(131);
-                       return(ENOMEM);
+                       return (ENOMEM);
                }
                bzero(f, fp->fr_size);
                error = ipf_inobjsz(softc, data, f, IPFOBJ_FRENTRY,
                                    fp->fr_size);
                if (error) {
                        KFREES(f, fp->fr_size);
-                       return(error);
+                       return (error);
                }
 
                fp = f;
@@ -4452,7 +4452,7 @@ frrequest(ipf_main_softc_t *softc, int unit, ioctlcmd_t 
req, caddr_t data,
                fp = (frentry_t *)data;
                if ((fp->fr_type & FR_T_BUILTIN) == 0) {
                        IPFERROR(7);
-                       return(EINVAL);
+                       return (EINVAL);
                }
                fp->fr_flags &= ~FR_COPIED;
        }
@@ -4918,7 +4918,7 @@ frrequest(ipf_main_softc_t *softc, int unit, ioctlcmd_t 
req, caddr_t data,
                        KFREES(fp, fp->fr_size);
                }
                RWLOCK_EXIT(&softc->ipf_mutex);
-               return(error);
+               return (error);
        }
 
        if (f == NULL) {
@@ -5073,7 +5073,7 @@ donenolock:
                }
                KFREES(fp, fp->fr_size);
        }
-       return(error);
+       return (error);
 }
 
 
@@ -5208,7 +5208,7 @@ ipf_findlookup(ipf_main_softc_t *softc, int unit, 
frentry_t *fr,
                break;
        }
 
-       return(ptr);
+       return (ptr);
 }
 
 
@@ -5237,7 +5237,7 @@ ipf_funcinit(ipf_main_softc_t *softc, frentry_t *fr)
                                err = (*ft->ipfu_init)(softc, fr);
                        break;
                }
-       return(err);
+       return (err);
 }
 
 
@@ -5279,8 +5279,8 @@ ipf_findfunc(ipfunc_t funcptr)
 
        for (ft = ipf_availfuncs; ft->ipfu_addr != NULL; ft++)
                if (ft->ipfu_addr == funcptr)
-                       return(funcptr);
-       return(NULL);
+                       return (funcptr);
+       return (NULL);
 }
 
 
@@ -5303,7 +5303,7 @@ ipf_resolvefunc(ipf_main_softc_t *softc, void *data)
        error = BCOPYIN(data, &res, sizeof(res));
        if (error != 0) {
                IPFERROR(123);
-               return(EFAULT);
*** 11801 LINES SKIPPED ***

Reply via email to