Index: core/fpdfapi/parser/cfdf_document.cpp |
diff --git a/core/fpdfapi/parser/cfdf_document.cpp b/core/fpdfapi/parser/cfdf_document.cpp |
index f54e59850694682514499cd5470fa11ece4b1466..d76ae1e642be69072ca7662537cbcf81281fd656 100644 |
--- a/core/fpdfapi/parser/cfdf_document.cpp |
+++ b/core/fpdfapi/parser/cfdf_document.cpp |
@@ -26,8 +26,8 @@ CFDF_Document::~CFDF_Document() { |
CFDF_Document* CFDF_Document::CreateNewDoc() { |
CFDF_Document* pDoc = new CFDF_Document; |
- pDoc->m_pRootDict = new CPDF_Dictionary(pDoc->GetByteStringPool()); |
- pDoc->AddIndirectObject(pDoc->m_pRootDict); |
+ pDoc->m_pRootDict = |
+ pDoc->NewIndirect<CPDF_Dictionary>(pDoc->GetByteStringPool()); |
pDoc->m_pRootDict->SetFor("FDF", |
new CPDF_Dictionary(pDoc->GetByteStringPool())); |
return pDoc; |