Re: [PATCH] netfilter: Fix switch statement warnings with recent gcc.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 07, 2015 at 11:05:42PM -0400, David Miller wrote:
> 
> More recent GCC warns about two kinds of switch statement uses:
> 
> 1) Switching on an enumeration, but not having an explicit case
>    statement for all members of the enumeration.  To show the
>    compiler this is intentional, we simply add a default case
>    with nothing more than a break statement.
> 
> 2) Switching on a boolean value.  I think this warning is dumb
>    but nevertheless you get it wholesale with -Wswitch.
> 
> This patch cures all such warnings in netfilter.
> 
> Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>

Acked-by: Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux