summaryrefslogtreecommitdiff
path: root/xfa
diff options
context:
space:
mode:
authordan sinclair <dsinclair@chromium.org>2018-02-19 18:34:03 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-02-19 18:34:03 +0000
commite53460ff2697299d42518f587c42409b0bd673df (patch)
treec477df856b2d1e02edbe3e88c9b7d14bfc88f81e /xfa
parent0f9e15cf365faf025d00e7df2565c8482a245953 (diff)
downloadpdfium-e53460ff2697299d42518f587c42409b0bd673df.tar.xz
Remove extraneous HasError checks
Duplicate checks, remove. Change-Id: Ic2f49651c50ed66328233817bc8cd24f7c9636c2 Reviewed-on: https://pdfium-review.googlesource.com/27330 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa')
-rw-r--r--xfa/fxfa/fm2js/cxfa_fmparser.cpp15
1 files changed, 0 insertions, 15 deletions
diff --git a/xfa/fxfa/fm2js/cxfa_fmparser.cpp b/xfa/fxfa/fm2js/cxfa_fmparser.cpp
index 536075b298..8baa59fb25 100644
--- a/xfa/fxfa/fm2js/cxfa_fmparser.cpp
+++ b/xfa/fxfa/fm2js/cxfa_fmparser.cpp
@@ -663,9 +663,6 @@ std::unique_ptr<CXFA_FMSimpleExpression> CXFA_FMParser::ParsePostExpression(
if (HasError() || !IncrementParseDepthAndCheck())
return nullptr;
- if (HasError())
- return nullptr;
-
uint32_t line = m_lexer->GetCurrentLine();
size_t expr_count = 0;
while (1) {
@@ -947,9 +944,6 @@ std::unique_ptr<CXFA_FMExpression> CXFA_FMParser::ParseBlockExpression() {
if (HasError() || !IncrementParseDepthAndCheck())
return nullptr;
- if (HasError())
- return nullptr;
-
uint32_t line = m_lexer->GetCurrentLine();
std::vector<std::unique_ptr<CXFA_FMExpression>> expressions;
while (1) {
@@ -1082,9 +1076,6 @@ CXFA_FMParser::ParseSubassignmentInForExpression() {
if (HasError() || !IncrementParseDepthAndCheck())
return nullptr;
- if (HasError())
- return nullptr;
-
if (m_token.m_type != TOKidentifier) {
m_error = true;
return nullptr;
@@ -1169,9 +1160,6 @@ std::unique_ptr<CXFA_FMExpression> CXFA_FMParser::ParseForeachExpression() {
if (HasError() || !IncrementParseDepthAndCheck())
return nullptr;
- if (HasError())
- return nullptr;
-
std::unique_ptr<CXFA_FMExpression> expr;
WideStringView wsIdentifier;
std::vector<std::unique_ptr<CXFA_FMSimpleExpression>> pAccessors;
@@ -1218,9 +1206,6 @@ std::unique_ptr<CXFA_FMExpression> CXFA_FMParser::ParseDoExpression() {
if (HasError() || !IncrementParseDepthAndCheck())
return nullptr;
- if (HasError())
- return nullptr;
-
uint32_t line = m_lexer->GetCurrentLine();
if (!NextToken())
return nullptr;