summaryrefslogtreecommitdiff
path: root/include/linux/overflow.h
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>2025-12-08 03:07:52 +0100
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2025-12-12 23:59:39 +0100
commit136209e6bd981e60db6c0e78f2919ff2f92312d4 (patch)
treecfe253c070f1bd5246431e51a9a86b2b3332a0e7 /include/linux/overflow.h
parentcc3b18f9fedec517e35b973d14670a37290f133c (diff)
i3c: adi: Fix confusing cleanup.h syntax
Initializing automatic __free variables to NULL without need (e.g. branches with different allocations), followed by actual allocation is in contrary to explicit coding rules guiding cleanup.h: "Given that the "__free(...) = NULL" pattern for variables defined at the top of the function poses this potential interdependency problem the recommendation is to always define and assign variables in one statement and not group variable definitions at the top of the function when __free() is used." Code does not have a bug, but is less readable and uses discouraged coding practice, so fix that by moving declaration to the place of assignment. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com> Link: https://patch.msgid.link/20251208020750.4727-4-krzysztof.kozlowski@oss.qualcomm.com Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'include/linux/overflow.h')
0 files changed, 0 insertions, 0 deletions