| OLD | NEW |
| 1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #include "xfa/fxfa/parser/cxfa_xml_parser.h" | 7 #include "xfa/fxfa/parser/cxfa_xml_parser.h" |
| 8 | 8 |
| 9 CXFA_XMLParser::CXFA_XMLParser(CFDE_XMLNode* pRoot, IFGAS_Stream* pStream) | 9 CXFA_XMLParser::CXFA_XMLParser(CFDE_XMLNode* pRoot, |
| 10 const CFX_RetainPtr<IFGAS_Stream>& pStream) |
| 10 : m_nElementStart(0), | 11 : m_nElementStart(0), |
| 11 m_dwCheckStatus(0), | 12 m_dwCheckStatus(0), |
| 12 m_dwCurrentCheckStatus(0), | 13 m_dwCurrentCheckStatus(0), |
| 13 m_pRoot(pRoot), | 14 m_pRoot(pRoot), |
| 14 m_pStream(pStream), | 15 m_pStream(pStream), |
| 15 m_pParser(new CFDE_XMLSyntaxParser), | 16 m_pParser(new CFDE_XMLSyntaxParser), |
| 16 m_pParent(pRoot), | 17 m_pParent(pRoot), |
| 17 m_pChild(nullptr), | 18 m_pChild(nullptr), |
| 18 m_NodeStack(16), | 19 m_NodeStack(16), |
| 19 m_syntaxParserResult(FDE_XmlSyntaxResult::None) { | 20 m_syntaxParserResult(FDE_XmlSyntaxResult::None) { |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 } | 168 } |
| 168 if (pPause && iCount > 500 && pPause->NeedToPauseNow()) { | 169 if (pPause && iCount > 500 && pPause->NeedToPauseNow()) { |
| 169 break; | 170 break; |
| 170 } | 171 } |
| 171 } | 172 } |
| 172 return (m_syntaxParserResult == FDE_XmlSyntaxResult::Error || | 173 return (m_syntaxParserResult == FDE_XmlSyntaxResult::Error || |
| 173 m_NodeStack.GetSize() != 1) | 174 m_NodeStack.GetSize() != 1) |
| 174 ? -1 | 175 ? -1 |
| 175 : m_pParser->GetStatus(); | 176 : m_pParser->GetStatus(); |
| 176 } | 177 } |
| OLD | NEW |