Skip to content

Commit ebc0d9f

Browse files
committed
Fix fuzzing crashes
1 parent 23ec401 commit ebc0d9f

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

lib/tokenize.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8641,7 +8641,7 @@ void Tokenizer::findGarbageCode() const
86418641
syntaxError(tok);
86428642
if (Token::Match(tok, "==|!=|<=|>= %comp%") && tok->strAt(-1) != "operator")
86438643
syntaxError(tok, tok->str() + " " + tok->strAt(1));
8644-
if (Token::simpleMatch(tok, ":: ::"))
8644+
if (Token::simpleMatch(tok, "::") && (!Token::match(tok->next(), "%name%") || tok->next()->isKeyword()))
86458645
syntaxError(tok);
86468646
}
86478647

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
n::template u
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
n i(){t i=0-::-t}

0 commit comments

Comments
 (0)