diff options
Diffstat (limited to 'meta/recipes-kernel/modutils/files/lex.l.diff')
-rw-r--r-- | meta/recipes-kernel/modutils/files/lex.l.diff | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/meta/recipes-kernel/modutils/files/lex.l.diff b/meta/recipes-kernel/modutils/files/lex.l.diff new file mode 100644 index 0000000000..65904b6b02 --- /dev/null +++ b/meta/recipes-kernel/modutils/files/lex.l.diff | |||
@@ -0,0 +1,33 @@ | |||
1 | --- modutils-2.4.26.orig/genksyms/lex.l | ||
2 | +++ modutils-2.4.26/genksyms/lex.l | ||
3 | @@ -130,6 +130,7 @@ | ||
4 | |||
5 | static int suppress_type_lookup, dont_want_brace_phrase; | ||
6 | static struct string_list *next_node; | ||
7 | + static int next_token = 0; | ||
8 | |||
9 | int token, count = 0; | ||
10 | struct string_list *cur_node; | ||
11 | @@ -144,7 +145,12 @@ | ||
12 | } | ||
13 | |||
14 | repeat: | ||
15 | - token = yylex1(); | ||
16 | + if (next_token != 0) { | ||
17 | + token = next_token; | ||
18 | + next_token = 0; | ||
19 | + } | ||
20 | + else | ||
21 | + token = yylex1(); | ||
22 | |||
23 | if (token == 0) | ||
24 | return 0; | ||
25 | @@ -425,7 +431,7 @@ | ||
26 | { | ||
27 | /* Put back the token we just read so's we can find it again | ||
28 | after registering the expression. */ | ||
29 | - unput(token); | ||
30 | + next_token = token; | ||
31 | |||
32 | lexstate = ST_NORMAL; | ||
33 | token = EXPRESSION_PHRASE; | ||