Re: [PATCH 1/3] bridge: Fix error path for kobject_init_and_add()

Greg Kroah-Hartman
2019-04-30T08:44:14Z

On Tue, Apr 30, 2019 at 10:28:15AM +1000, Tobin C. Harding wrote:
> Currently error return from kobject_init_and_add() is not followed by a
> call to kobject_put(). This means there is a memory leak.
>
> Add call to kobject_put() in error path of kobject_init_and_add().
>
> Signed-off-by: Tobin C. Harding <tobin@kernel.org>

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>