Index: fpdfsdk/fpdfeditpage.cpp |
diff --git a/fpdfsdk/fpdfeditpage.cpp b/fpdfsdk/fpdfeditpage.cpp |
index e3777d4f8411570cf00b7367da374a5c5597f3a1..f124db8f9ed1a6cfc33deb567ba8962698107d7e 100644 |
--- a/fpdfsdk/fpdfeditpage.cpp |
+++ b/fpdfsdk/fpdfeditpage.cpp |
@@ -105,6 +105,7 @@ DLLEXPORT FPDF_PAGE STDCALL FPDFPage_New(FPDF_DOCUMENT document, |
if (!pDoc) |
return nullptr; |
+ // TODO(dsinclair): Verify if this is correct for XFA page counts. |
page_index = std::min(std::max(page_index, 0), pDoc->GetPageCount()); |
CPDF_Dictionary* pPageDict = pDoc->CreateNewPage(page_index); |
if (!pPageDict) |