simplifyIfAddBraces : Fixed a segmentation fault

This commit is contained in:
Daniel Marjamäki 2008-12-22 19:26:23 +00:00
parent 78f46c5848
commit c3b9b3dfd5
1 changed files with 1 additions and 1 deletions

View File

@ -1237,7 +1237,7 @@ bool Tokenizer::simplifyIfAddBraces()
}
// ')' should be followed by '{'
if ( TOKEN::Match(tok, ") {") )
if (!tok || TOKEN::Match(tok, ") {"))
continue;
// insert open brace..