nfnetlink_log: stop reference leak
Subsystems (2)
PATCH 2/10 nfnetlink_log: stop reference leak
Stop reference leaking in nfulnl_log_packet(). If we start a timer we are already taking another reference.
Signed-off-by Michał Mirosław <[email protected]>
net/netfilter/nfnetlink_log.c renamed from net/netfilter/nfnetlink_log.c.0 +4 -3
@@ -705,15 +705,16 @@ nfulnl_log_packet(unsigned int pf, inst->timer.expires = jiffies + (inst->flushtimeout*HZ /100 );add_timer (&inst->timer); } -spin_unlock_bh (&inst->lock); +unlock_and_release: +spin_unlock_bh (&inst->lock); +instance_put (inst);return ; alloc_failure: -spin_unlock_bh (&inst->lock); -instance_put (inst);UDEBUG ("error allocating skb\n" );/* FIXME: statistics */ + goto unlock_and_release; } static int
Quoted 2 lines · Micha³ Miros³aw
Stop reference leaking in
nfulnl_log_packet(). If we start a timer we are already taking another reference.
Good catch, applied. I'll forward this one to -stable.