Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2311)

Unified Diff: core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp

Issue 2275593002: IndirectObjectHolder API updates (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Missed one Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | core/fpdfapi/fpdf_parser/cfdf_document.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
diff --git a/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp b/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
index c20a483764ae1651242186f00e012e6e52e2e886..9ad1d060ccfe4535601b2db89be41e1f6fd1dfda 100644
--- a/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
+++ b/core/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
@@ -1239,7 +1239,7 @@ int32_t CPDF_Creator::WriteOldIndirectObject(uint32_t objnum) {
bool bObjStm = (object_type == 2) && m_pEncryptDict && !m_pXRefStream;
if (m_pParser->IsVersionUpdated() || m_bSecurityChanged || bExistInMap ||
bObjStm) {
- CPDF_Object* pObj = m_pDocument->GetIndirectObject(objnum);
+ CPDF_Object* pObj = m_pDocument->GetOrParseIndirectObject(objnum);
if (!pObj) {
m_ObjectOffset[objnum] = 0;
return 0;
@@ -1703,7 +1703,7 @@ int32_t CPDF_Creator::WriteDoc_Stage4(IFX_Pause* pPause) {
return -1;
}
} else {
- if (m_File.AppendDWord(m_pDocument->m_LastObjNum + 1) < 0) {
+ if (m_File.AppendDWord(m_pDocument->GetLastObjNum() + 1) < 0) {
return -1;
}
if (m_File.AppendString(" 0 obj <<") < 0) {
« no previous file with comments | « no previous file | core/fpdfapi/fpdf_parser/cfdf_document.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698