mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
of: overlay: kmemleak in dup_and_fixup_symbol_prop()
commit 478ff649b1c8eb2409b1a54fb75eb46f7c29f140 upstream.
kmemleak reports several memory leaks from devicetree unittest.
This is the fix for problem 4 of 5.
target_path was not freed in the non-error path.
Fixes: e0a58f3e08 ("of: overlay: remove a dependency on device node full_name")
Reported-by: Erhard F. <[email protected]>
Signed-off-by: Frank Rowand <[email protected]>
Signed-off-by: Rob Herring <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
93ef21bb1a
commit
4c2a34f9f4
1 changed files with 2 additions and 0 deletions
|
|
@ -261,6 +261,8 @@ static struct property *dup_and_fixup_symbol_prop(
|
|||
|
||||
of_property_set_flag(new_prop, OF_DYNAMIC);
|
||||
|
||||
kfree(target_path);
|
||||
|
||||
return new_prop;
|
||||
|
||||
err_free_new_prop:
|
||||
|
|
|
|||
Loading…
Reference in a new issue