From a61c01ea4527dd98699005099e9335a4a842b545 Mon Sep 17 00:00:00 2001 From: dsinclair Date: Wed, 24 Aug 2016 10:31:23 -0700 Subject: Move parser out of IndirectObjectHolder This Cl moves the parser out of the indirect object holder and into the CPDF_Document where it is used. Review-Url: https://codereview.chromium.org/2277433003 --- core/fpdfapi/fpdf_parser/cpdf_parser.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'core/fpdfapi/fpdf_parser/cpdf_parser.cpp') diff --git a/core/fpdfapi/fpdf_parser/cpdf_parser.cpp b/core/fpdfapi/fpdf_parser/cpdf_parser.cpp index 26adf7bb13..ffd3f79a62 100644 --- a/core/fpdfapi/fpdf_parser/cpdf_parser.cpp +++ b/core/fpdfapi/fpdf_parser/cpdf_parser.cpp @@ -982,6 +982,8 @@ FX_BOOL CPDF_Parser::LoadCrossRefV5(FX_FILESIZE* pos, FX_BOOL bMainXRef) { if (m_pDocument) { CPDF_Dictionary* pRootDict = m_pDocument->GetRoot(); if (pRootDict && pRootDict->GetObjNum() == pObject->m_ObjNum) { + // If |pObject| has an objnum assigned then this will leak as Release() + // will early exit. if (pObject->IsStream()) pObject->Release(); return FALSE; -- cgit v1.2.3