From: Kaixu Xia Date: Fri, 6 Nov 2020 08:20:13 +0000 (+0800) Subject: netfilter: Remove unnecessary conversion to bool X-Git-Tag: v5.11-rc1~169^2~25^2~7 X-Git-Url: https://gentwo.org/gitweb/?a=commitdiff_plain;h=0ef083d51ba1f4a2e890807d49d53ad20eee0ffd;p=linux%2F.git netfilter: Remove unnecessary conversion to bool Here we could use the '!=' expression to fix the following coccicheck warning: ./net/netfilter/xt_nfacct.c:30:41-46: WARNING: conversion to bool not needed here Reported-by: Tosk Robot Signed-off-by: Kaixu Xia Signed-off-by: Pablo Neira Ayuso --- diff --git a/net/netfilter/xt_nfacct.c b/net/netfilter/xt_nfacct.c index a97c2259bbc8..7c6bf1c16813 100644 --- a/net/netfilter/xt_nfacct.c +++ b/net/netfilter/xt_nfacct.c @@ -27,7 +27,7 @@ static bool nfacct_mt(const struct sk_buff *skb, struct xt_action_param *par) overquota = nfnl_acct_overquota(xt_net(par), info->nfacct); - return overquota == NFACCT_UNDERQUOTA ? false : true; + return overquota != NFACCT_UNDERQUOTA; } static int