Re: [PATCH] livepatch: Fix leak on klp_init_patch_early failure path

From: David Vernet
Date: Tue Dec 14 2021 - 13:27:07 EST


Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> wrote on Tue [2021-Dec-14 16:52:41 +0100]:
> You are FORCED TO call kobject_put() after kobject_init() is called.
> Anything else is a bug.

Ack, thanks for confirming, Greg. I'll send out a v2 of the patch that fixes the
leak and addresses the issue that Josh identified.

- David