Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

kconfig: narrow the scope of variables in the lexer

The variables, "ts" and "i", are used locally in the action of
the [ \t]+ pattern in the <HELP> start state.

Define them where they are used.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

+2 -1
+2 -1
scripts/kconfig/lexer.l
··· 85 85 86 86 %% 87 87 int str = 0; 88 - int ts, i; 89 88 90 89 #.* /* ignore comment */ 91 90 [ \t]* /* whitespaces */ ··· 195 196 196 197 <HELP>{ 197 198 [ \t]+ { 199 + int ts, i; 200 + 198 201 ts = 0; 199 202 for (i = 0; i < yyleng; i++) { 200 203 if (yytext[i] == '\t')