Skip to content
Commit 8a622e6d authored by Dragos Tarcatu's avatar Dragos Tarcatu Committed by Greg Kroah-Hartman
Browse files

ASoC: topology: Fix memleak in soc_tplg_manifest_load()

commit 242c46c0 upstream.

In case of ABI version mismatch, _manifest needs to be freed as
it is just a copy of the original topology manifest. However, if
a driver manifest handler is defined, that would get executed and
the cleanup is never reached. Fix that by getting the return status
of manifest() instead of returning directly.

Fixes: 583958fa

 ("ASoC: topology: Make manifest backward compatible from ABI v4")
Signed-off-by: default avatarDragos Tarcatu <dragos_tarcatu@mentor.com>
Link: https://lore.kernel.org/r/20200207185325.22320-3-dragos_tarcatu@mentor.com
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a7d67564
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment