Skip to content
Commit 6d32f7a3 authored by Joe Perches's avatar Joe Perches Committed by Linus Torvalds
Browse files

checkpatch: improve the unnecessary initialisers tests



Global and static variables don't need to be initialized to 0.

There is already a test for this but the output message doesn't
mention booleans initialized to false.

Improve the output message and the test by adding various forms
with possible specific integer types and possible multiple zeros.

Miscellanea:

o Use a variable to hold the possible 0 test

Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarShailendra Verma <shailendra.v@samsung.com>
Tested-by: default avatarShailendra Verma <shailendra.v@samsung.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 369c8dd3
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