Skip to content

Commit

Permalink
netfilter: nf_conntrack: remove double assignment
Browse files Browse the repository at this point in the history
The protonet pointer will unconditionally be rewritten, so just do the
needed assignment first.

Signed-off-by: Aaron Conole <aconole@bytheb.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Aaron Conole authored and Pablo Neira Ayuso committed Apr 13, 2017
1 parent 7925056 commit 809c2d9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions net/netfilter/nf_conntrack_proto.c
Original file line number Diff line number Diff line change
Expand Up @@ -441,9 +441,8 @@ EXPORT_SYMBOL_GPL(nf_ct_l4proto_unregister_one);
void nf_ct_l4proto_pernet_unregister_one(struct net *net,
struct nf_conntrack_l4proto *l4proto)
{
struct nf_proto_net *pn = NULL;
struct nf_proto_net *pn = nf_ct_l4proto_net(net, l4proto);

pn = nf_ct_l4proto_net(net, l4proto);
if (pn == NULL)
return;

Expand Down

0 comments on commit 809c2d9

Please sign in to comment.