mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-11-01 17:08:10 +00:00
82c2d81361
While iterating over child nodes with the for_each functions, if control is transferred from the middle of the loop, as in the case of a break or return or goto, there is no decrement in the reference counter thus ultimately resulting in a memory leak. Add this script to detect potential memory leaks caused by the absence of of_node_put() before break, goto, or, return statements which transfer control outside the loop. Signed-off-by: Sumera Priyadarsini <sylphrenadin@gmail.com> Signed-off-by: Julia Lawall <julia.lawall@inria.fr> |
||
---|---|---|
.. | ||
device_node_continue.cocci | ||
fen.cocci | ||
for_each_child.cocci | ||
itnull.cocci | ||
list_entry_update.cocci | ||
use_after_iter.cocci |