Index: fpdfsdk/src/fpdf_flatten.cpp |
diff --git a/fpdfsdk/src/fpdf_flatten.cpp b/fpdfsdk/src/fpdf_flatten.cpp |
index 210df63d3e7e15b5baf14d1817d60df8a0fcced2..b2303f36aa0758f87b9a0e7177a1a5495fbf1800 100644 |
--- a/fpdfsdk/src/fpdf_flatten.cpp |
+++ b/fpdfsdk/src/fpdf_flatten.cpp |
@@ -310,11 +310,11 @@ void GetOffset(FX_FLOAT& fa, |
} |
DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) { |
+ CPDF_Page* pPage = CPDFPageFromFPDFPage(page); |
if (!page) { |
return FLATTEN_FAIL; |
} |
- CPDF_Page* pPage = (CPDF_Page*)(page); |
CPDF_Document* pDocument = pPage->m_pDocument; |
CPDF_Dictionary* pPageDict = pPage->m_pFormDict; |