Skip to content

Commit 9162aa7

Browse files
Fix #14878 fuzzing crash (null-pointer-use) in Tokenizer::simplifyUsing() (#8682)
1 parent 56a055d commit 9162aa7

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

lib/tokenize.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3470,6 +3470,8 @@ bool Tokenizer::simplifyUsing()
34703470
skip = true;
34713471
simplifyUsingError(usingStart, usingEnd);
34723472
}
3473+
if (!after)
3474+
syntaxError(tok1);
34733475
tok1 = after->previous();
34743476
}
34753477

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
using C=C*;C{{}}

0 commit comments

Comments
 (0)