Date: Wed, 09 May 2018 14:13:37 -0700 From: John Baldwin <jhb@freebsd.org> To: Warner Losh <imp@bsdimp.com> Cc: Cy Schubert <cy@freebsd.org>, src-committers <src-committers@freebsd.org>, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r333393 - head/sys/contrib/ipfilter/netinet Message-ID: <1843086.zoJA0hnD5f@ralph.baldwin.cx> In-Reply-To: <CANCZdfp=aAV3Ue%2Bg9Yx64V_v7QP9_f8OuzA0OBv=vbBdc-dMeg@mail.gmail.com> References: <201805090207.w49279t8006603@repo.freebsd.org> <1872360.cC9XDcqkuS@ralph.baldwin.cx> <CANCZdfp=aAV3Ue%2Bg9Yx64V_v7QP9_f8OuzA0OBv=vbBdc-dMeg@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday, May 09, 2018 02:29:05 PM Warner Losh wrote: > On Wed, May 9, 2018 at 10:52 AM, John Baldwin <jhb@freebsd.org> wrote: > > > On Wednesday, May 09, 2018 10:02:06 AM Warner Losh wrote: > > > On Wed, May 9, 2018 at 8:58 AM, John Baldwin <jhb@freebsd.org> wrote: > > > > > > > On Wednesday, May 09, 2018 02:07:09 AM Cy Schubert wrote: > > > > > Author: cy > > > > > Date: Wed May 9 02:07:09 2018 > > > > > New Revision: 333393 > > > > > URL: https://svnweb.freebsd.org/changeset/base/333393 > > > > > > > > > > Log: > > > > > Document intentional fallthrough. (CID 976535) > > > > > > > > > > MFC after: 1 week > > > > > > > > > > Modified: > > > > > head/sys/contrib/ipfilter/netinet/fil.c > > > > > > > > > > Modified: head/sys/contrib/ipfilter/netinet/fil.c > > > > > ============================================================ > > > > ================== > > > > > --- head/sys/contrib/ipfilter/netinet/fil.c Wed May 9 02:02:58 > > 2018 > > > > (r333392) > > > > > +++ head/sys/contrib/ipfilter/netinet/fil.c Wed May 9 02:07:09 > > 2018 > > > > (r333393) > > > > > @@ -1299,6 +1299,7 @@ ipf_pr_icmp(fin) > > > > > } > > > > > } > > > > > #endif > > > > > + /* fallthrough is intentional */ > > > > > case ICMP_SOURCEQUENCH : > > > > > case ICMP_REDIRECT : > > > > > case ICMP_TIMXCEED : > > > > > > > > Hmm, normal FreeBSD style here is to use /* FALLTHROUGH */, and there > > are > > > > three other instances of that style in ipfilter already (and none > > others > > > > using this comment style). > > > > > > > > > > /* FALLTHROUGH */ is actually an old-school lint directive that other > > tools > > > have picked up. > > > > Yes, but it is still the dominant style in the tree even if it has come > > from > > lint. > > > > Agreed. I wasn't arguing, just saying it has a long history and everybody > does it today even though lint's relevance has faded. I do think that clang and gcc will look for 'fallthrough' (case insensitive) for their built-in warnings. C<mumble> has also added a [[fallthrough]] attribute apparently? -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1843086.zoJA0hnD5f>