Commit 7c523338 authored by Perry Kundert's avatar Perry Kundert

Remove unnnecessary NUL termination of yytext (as it may contain NULs)

parent 14ca1f6f
...@@ -1828,9 +1828,6 @@ class lexer ...@@ -1828,9 +1828,6 @@ class lexer
// closing quote // closing quote
case '\"': case '\"':
{ {
// terminate yytext
add('\0');
--yylen;
return token_type::value_string; return token_type::value_string;
} }
...@@ -2576,10 +2573,6 @@ scan_number_done: ...@@ -2576,10 +2573,6 @@ scan_number_done:
// we are done scanning a number) // we are done scanning a number)
unget(); unget();
// terminate token
add('\0');
--yylen;
char* endptr = nullptr; char* endptr = nullptr;
errno = 0; errno = 0;
......
Markdown is supported
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