lkml.org 
[lkml]   [2017]   [Nov]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Date
    Subject[PATCH 3.16 258/294] netfilter; Add some missing default cases to switch statements in nft_reject.
    3.16.50-rc1 review patch.  If anyone has any objections, please let me know.

    ------------------

    From: "David S. Miller" <davem@davemloft.net>

    commit 129d23a56623eea0947a05288158d76dc7f2f0ac upstream.

    This fixes:

    ====================
    net/netfilter/nft_reject.c: In function ‘nft_reject_dump’:
    net/netfilter/nft_reject.c:61:2: warning: enumeration value ‘NFT_REJECT_TCP_RST’ not handled in switch [-Wswitch]
    switch (priv->type) {
    ^
    net/netfilter/nft_reject.c:61:2: warning: enumeration value ‘NFT_REJECT_ICMPX_UNREACH’ not handled in switch [-Wswi\
    tch]
    net/netfilter/nft_reject_inet.c: In function ‘nft_reject_inet_dump’:
    net/netfilter/nft_reject_inet.c:105:2: warning: enumeration value ‘NFT_REJECT_TCP_RST’ not handled in switch [-Wswi\
    tch]
    switch (priv->type) {
    ^
    ====================

    Signed-off-by: David S. Miller <davem@davemloft.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    Signed-off-by: Arnd Bergmann <arnd@arndb.de>
    Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
    ---
    net/netfilter/nft_reject.c | 2 ++
    1 file changed, 2 insertions(+)

    --- a/net/netfilter/nft_reject.c
    +++ b/net/netfilter/nft_reject.c
    @@ -61,6 +61,8 @@ int nft_reject_dump(struct sk_buff *skb,
    if (nla_put_u8(skb, NFTA_REJECT_ICMP_CODE, priv->icmp_code))
    goto nla_put_failure;
    break;
    + default:
    + break;
    }

    return 0;
    \
     
     \ /
      Last update: 2017-11-08 20:59    [W:4.050 / U:0.136 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site