Skip to content

Commit

Permalink
netfilter: nfnetlink_queue: avoid peer_portid test
Browse files Browse the repository at this point in the history
The portid is set to NETLINK_CB(skb).portid at create time.
The run-time check will always be false.

Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
  • Loading branch information
Florian Westphal authored and Pablo Neira Ayuso committed May 26, 2013
1 parent 0799567 commit 9d5242b
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions net/netfilter/nfnetlink_queue_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -509,10 +509,6 @@ __nfqnl_enqueue_packet(struct net *net, struct nfqnl_instance *queue,
}
spin_lock_bh(&queue->lock);

if (!queue->peer_portid) {
err = -EINVAL;
goto err_out_free_nskb;
}
if (queue->queue_total >= queue->queue_maxlen) {
if (queue->flags & NFQA_CFG_F_FAIL_OPEN) {
failopen = 1;
Expand Down

0 comments on commit 9d5242b

Please sign in to comment.