mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-30 15:41:12 +00:00
Fix linecounting mistake in try_digraph
This commit is contained in:
parent
3424b7227b
commit
36cdffe1b3
1 changed files with 5 additions and 0 deletions
5
lexer.c
5
lexer.c
|
@ -318,6 +318,11 @@ static int lex_try_digraph(lex_file *lex, int ch)
|
|||
{
|
||||
int c2;
|
||||
c2 = lex_fgetc(lex);
|
||||
/* we just used fgetc() so count lines
|
||||
* need to offset a \n the ungetch would recognize
|
||||
*/
|
||||
if (!lex->push_line && c2 == '\n')
|
||||
lex->line++;
|
||||
if (ch == '<' && c2 == ':')
|
||||
return '[';
|
||||
else if (ch == ':' && c2 == '>')
|
||||
|
|
Loading…
Reference in a new issue