From 7981d15a799e3bdfaf6bd3e04fc08a6a43d143ec Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Thu, 11 Jan 2018 14:26:01 +0000 Subject: Add jumbo build support for fdrm, fpdfdoc and fxcrt. BUG=pdfium:964 Change-Id: Ifde885861aeafac803948bd537de826e2a3fddca Reviewed-on: https://pdfium-review.googlesource.com/22732 Commit-Queue: dsinclair Reviewed-by: dsinclair --- core/fpdfdoc/cpdf_structtree.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'core/fpdfdoc/cpdf_structtree.cpp') diff --git a/core/fpdfdoc/cpdf_structtree.cpp b/core/fpdfdoc/cpdf_structtree.cpp index 48b83f555c..97db691425 100644 --- a/core/fpdfdoc/cpdf_structtree.cpp +++ b/core/fpdfdoc/cpdf_structtree.cpp @@ -15,8 +15,6 @@ namespace { -const int nMaxRecursion = 32; - bool IsTagged(const CPDF_Document* pDoc) { const CPDF_Dictionary* pCatalog = pDoc->GetRoot(); const CPDF_Dictionary* pMarkInfo = pCatalog->GetDictFor("MarkInfo"); @@ -87,7 +85,8 @@ RetainPtr CPDF_StructTree::AddPageNode( CPDF_Dictionary* pDict, std::map>* map, int nLevel) { - if (nLevel > nMaxRecursion) + static constexpr int kStructTreeMaxRecursion = 32; + if (nLevel > kStructTreeMaxRecursion) return nullptr; auto it = map->find(pDict); -- cgit v1.2.3