mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-23 20:33:05 +00:00
properly fill the token string for TOKEN_ATTRIBUTE_*
This commit is contained in:
parent
2c2bfab8bc
commit
b38b3b08bd
1 changed files with 2 additions and 0 deletions
2
lexer.c
2
lexer.c
|
@ -1117,6 +1117,7 @@ int lex_do(lex_file *lex)
|
|||
case '[':
|
||||
nextch = lex_getch(lex);
|
||||
if (nextch == '[') {
|
||||
lex_tokench(lex, ch);
|
||||
lex_tokench(lex, nextch);
|
||||
lex_endtoken(lex);
|
||||
return (lex->tok.ttype = TOKEN_ATTRIBUTE_OPEN);
|
||||
|
@ -1136,6 +1137,7 @@ int lex_do(lex_file *lex)
|
|||
case ']':
|
||||
nextch = lex_getch(lex);
|
||||
if (nextch == ']') {
|
||||
lex_tokench(lex, ch);
|
||||
lex_tokench(lex, nextch);
|
||||
lex_endtoken(lex);
|
||||
return (lex->tok.ttype = TOKEN_ATTRIBUTE_CLOSE);
|
||||
|
|
Loading…
Reference in a new issue