Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
leds: mt6360: Fix memory leak in mt6360_init_isnk_properties()
The fwnode_for_each_child_node() loop requires manual intervention to decrement the child refcount in case of an early return. Add the missing calls to fwnode_handle_put(child) to avoid memory leaks in the error paths. Cc: [email protected] Fixes: 679f865 ("leds: Add mt6360 driver") Signed-off-by: Javier Carrasco <[email protected]> Acked-by: Pavel Machek <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Lee Jones <[email protected]>
- Loading branch information