aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFengguang Wu <fengguang.wu@intel.com>2013-12-27 05:13:03 -0500
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>2014-03-06 03:31:42 -0500
commit9562cf28d1b48d0545d7b5dd2995d00b45e1cb53 (patch)
tree94b81097af0e0af685c828048b9fe0975e9d551e
parent35f6e63abec350733d9a51c0c52569a6a70643c4 (diff)
netfilter: ipset: Add hash: fix coccinelle warnings
net/netfilter/ipset/ip_set_hash_netnet.c:115:8-9: WARNING: return of 0/1 in function 'hash_netnet4_data_list' with return type bool /c/kernel-tests/src/cocci/net/netfilter/ipset/ip_set_hash_netnet.c:338:8-9: WARNING: return of 0/1 in function 'hash_netnet6_data_list' with return type bool Return statements in functions returning bool should use true/false instead of 1/0. Generated by: coccinelle/misc/boolreturn.cocci Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
-rw-r--r--net/netfilter/ipset/ip_set_hash_netnet.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/net/netfilter/ipset/ip_set_hash_netnet.c b/net/netfilter/ipset/ip_set_hash_netnet.c
index 6226803fc490..4e7261df8961 100644
--- a/net/netfilter/ipset/ip_set_hash_netnet.c
+++ b/net/netfilter/ipset/ip_set_hash_netnet.c
@@ -112,10 +112,10 @@ hash_netnet4_data_list(struct sk_buff *skb,
112 (flags && 112 (flags &&
113 nla_put_net32(skb, IPSET_ATTR_CADT_FLAGS, htonl(flags)))) 113 nla_put_net32(skb, IPSET_ATTR_CADT_FLAGS, htonl(flags))))
114 goto nla_put_failure; 114 goto nla_put_failure;
115 return 0; 115 return false;
116 116
117nla_put_failure: 117nla_put_failure:
118 return 1; 118 return true;
119} 119}
120 120
121static inline void 121static inline void
@@ -334,10 +334,10 @@ hash_netnet6_data_list(struct sk_buff *skb,
334 (flags && 334 (flags &&
335 nla_put_net32(skb, IPSET_ATTR_CADT_FLAGS, htonl(flags)))) 335 nla_put_net32(skb, IPSET_ATTR_CADT_FLAGS, htonl(flags))))
336 goto nla_put_failure; 336 goto nla_put_failure;
337 return 0; 337 return false;
338 338
339nla_put_failure: 339nla_put_failure:
340 return 1; 340 return true;
341} 341}
342 342
343static inline void 343static inline void