Re: [PATCH net] net/sched: act_ipt: fix refcount leak when replace fails

2019-02-24 Thread David Miller
From: Davide Caratti Date: Fri, 22 Feb 2019 12:33:25 +0100 > After commit 4e8ddd7f1758 ("net: sched: don't release reference on action > overwrite"), the error path of all actions was converted to drop refcount > also when the action was being overwritten. But we forgot act_ipt_init(), > in case

[PATCH net] net/sched: act_ipt: fix refcount leak when replace fails

2019-02-22 Thread Davide Caratti
After commit 4e8ddd7f1758 ("net: sched: don't release reference on action overwrite"), the error path of all actions was converted to drop refcount also when the action was being overwritten. But we forgot act_ipt_init(), in case allocation of 'tname' was not successful: # tc action add action xt