diff options
author | Erik Verbruggen <erik.verbruggen@nokia.com> | 2011-10-17 10:24:39 +0200 |
---|---|---|
committer | Erik Verbruggen <erik.verbruggen@nokia.com> | 2011-10-17 11:17:46 +0200 |
commit | 29dff7221d7c24aa6db78fc63a3588d01b8143de (patch) | |
tree | ff34e273f04cd1c1991909ee80cf072802e62439 /src/libs/3rdparty/cplusplus/Parser.h | |
parent | 7e3d41da58876a16cc681201268af4ef1c7d5041 (diff) |
Fixed stack-overflow when parsing insanely nested compound statements.
Thanks to Clang's parser_overflow.cpp which has >16000 nested compound
statements to check exactly the same.
Change-Id: I2b604f8ceb01115d7fe950994e0677a081e99481
Reviewed-by: Christian Kamm <christian.d.kamm@nokia.com>
Diffstat (limited to 'src/libs/3rdparty/cplusplus/Parser.h')
-rw-r--r-- | src/libs/3rdparty/cplusplus/Parser.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libs/3rdparty/cplusplus/Parser.h b/src/libs/3rdparty/cplusplus/Parser.h index 0896959fd4..1deb6269c0 100644 --- a/src/libs/3rdparty/cplusplus/Parser.h +++ b/src/libs/3rdparty/cplusplus/Parser.h @@ -315,6 +315,7 @@ private: bool _inObjCImplementationContext: 1; bool _inExpressionStatement: 1; int _expressionDepth; + int _statementDepth; MemoryPool _expressionStatementTempPool; std::map<unsigned, TemplateArgumentListEntry> _templateArgumentList; |