Commit 2480f53f authored by Masahiro Yamada's avatar Masahiro Yamada
Browse files

genksyms: refactor the return points in the for-loop in __add_symbol()



free_list() must be called before returning from this for-loop.

Swap 'break' and the combination of free_list() and 'return'.

This reduces the code and minimizes the risk of introducing memory
leaks in future changes.

Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
parent f034d186
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment