aboutsummaryrefslogtreecommitdiff
path: root/scripts/gdb/linux/utils.py
diff options
context:
space:
mode:
authorPierre-Louis Bossart <[email protected]>2021-10-25 13:59:29 -0500
committerMark Brown <[email protected]>2021-10-27 11:31:11 +0100
commit46ae0b3f554a323322a770c0edee50aa8019a655 (patch)
tree1eb471ff4951cc8716b9d8c9bc541e1cc5786eb4 /scripts/gdb/linux/utils.py
parent765e08bdc7faa44b13bf96df4663a580d68a1c49 (diff)
ASoC: nau8821: clarify out-of-bounds check
cppcheck reports a false positive sound/soc/codecs/nau8821.c:390:17: error: Array 'dmic_speed_sel[4]' accessed at index 4, which is out of bounds. [arrayIndexOutOfBounds] dmic_speed_sel[i].param, dmic_speed_sel[i].val); ^ sound/soc/codecs/nau8821.c:378:2: note: After for loop, i has value 4 for (i = 0 ; i < 4 ; i++) ^ sound/soc/codecs/nau8821.c:390:17: note: Array index out of bounds dmic_speed_sel[i].param, dmic_speed_sel[i].val); ^ While the code is not incorrect, we can deal with the out-of-bounds check in a clearer way that makes static analysis happy. Signed-off-by: Pierre-Louis Bossart <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions