summaryrefslogtreecommitdiff
path: root/core/include
diff options
context:
space:
mode:
authorWei Li <weili@chromium.org>2016-01-08 14:36:59 -0800
committerWei Li <weili@chromium.org>2016-01-08 14:36:59 -0800
commit8e3f8931c5dfb22ab3e0cf98821e2cca9369d69e (patch)
tree6f468c2662d3142a10d87de33bd3a00a0369e98f /core/include
parent1b97664bc5b84c7a2b87cc656f8c6a0476f9b71f (diff)
downloadpdfium-8e3f8931c5dfb22ab3e0cf98821e2cca9369d69e.tar.xz
Merge to XFA: Fix infinite loop caused by parsing same indirect objects
BUG=pdfium:343 TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1569343002 . (cherry picked from commit 149f1db8bba85bdf2b40d330c38f2478695ca0d5) Review URL: https://codereview.chromium.org/1575663002 .
Diffstat (limited to 'core/include')
-rw-r--r--core/include/fpdfapi/fpdf_parser.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/include/fpdfapi/fpdf_parser.h b/core/include/fpdfapi/fpdf_parser.h
index 756850932e..e1901ebdce 100644
--- a/core/include/fpdfapi/fpdf_parser.h
+++ b/core/include/fpdfapi/fpdf_parser.h
@@ -9,6 +9,7 @@
#include <map>
#include <memory>
+#include <set>
#include "core/include/fpdfapi/fpdf_objects.h"
#include "core/include/fxcrt/fx_system.h"
@@ -536,6 +537,9 @@ class CPDF_Parser {
// streams in |m_ObjectStreamMap| are valid.
std::map<CPDF_StreamAcc*, StreamObjectCache> m_ObjCache;
+ // All indirect object numbers that are being parsed.
+ std::set<FX_DWORD> m_ParsingObjNums;
+
friend class CPDF_Creator;
friend class CPDF_DataAvail;
};