diff options
author | Florian Westphal <fw@strlen.de> | 2021-11-26 13:04:03 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2021-11-30 23:15:11 +0100 |
commit | b43c2793f5e9910862e8fe07846b74e45b104501 (patch) | |
tree | 97b974afa3b90c18c128299fa3ac1c651d699435 /net | |
parent | 34d8778a943761121f391b7921f79a7adbe1feaf (diff) | |
download | linux-stable-b43c2793f5e9910862e8fe07846b74e45b104501.tar.gz linux-stable-b43c2793f5e9910862e8fe07846b74e45b104501.tar.bz2 linux-stable-b43c2793f5e9910862e8fe07846b74e45b104501.zip |
netfilter: nfnetlink_queue: silence bogus compiler warning
net/netfilter/nfnetlink_queue.c:601:36: warning: variable 'ctinfo' is
uninitialized when used here [-Wuninitialized]
if (ct && nfnl_ct->build(skb, ct, ctinfo, NFQA_CT, NFQA_CT_INFO) < 0)
ctinfo is only uninitialized if ct == NULL. Init it to 0 to silence this.
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net')
-rw-r--r-- | net/netfilter/nfnetlink_queue.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/netfilter/nfnetlink_queue.c b/net/netfilter/nfnetlink_queue.c index 4acc4b8e9fe5..5837e8efc9c2 100644 --- a/net/netfilter/nfnetlink_queue.c +++ b/net/netfilter/nfnetlink_queue.c @@ -387,7 +387,7 @@ nfqnl_build_packet_message(struct net *net, struct nfqnl_instance *queue, struct net_device *indev; struct net_device *outdev; struct nf_conn *ct = NULL; - enum ip_conntrack_info ctinfo; + enum ip_conntrack_info ctinfo = 0; struct nfnl_ct_hook *nfnl_ct; bool csum_verify; char *secdata = NULL; |