Index: fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp |
diff --git a/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp b/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp |
index 8db16bf4e952904b163efefa66504d6938b8d532..2d74c02d23b3cc41f8f9f1fbac7e16a2d09c41df 100644 |
--- a/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp |
+++ b/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp |
@@ -191,11 +191,8 @@ void CPDFXFA_Document::RemovePage(CPDFXFA_Page* page) { |
m_XFAPageList.SetAt(page->GetPageIndex(), nullptr); |
} |
-CPDFSDK_Document* CPDFXFA_Document::GetSDKDocument( |
- CPDFSDK_Environment* pFormFillEnv) { |
- if (!m_pSDKDoc && pFormFillEnv) |
- m_pSDKDoc.reset(new CPDFSDK_Document(this, pFormFillEnv)); |
- return m_pSDKDoc.get(); |
+void CPDFXFA_Document::SetSDKDoc(std::unique_ptr<CPDFSDK_Document> pSDKDoc) { |
+ m_pSDKDoc.reset(pSDKDoc.release()); |
} |
void CPDFXFA_Document::ClearChangeMark() { |