| Index: fpdfsdk/src/fpdf_progressive.cpp
|
| diff --git a/fpdfsdk/src/fpdf_progressive.cpp b/fpdfsdk/src/fpdf_progressive.cpp
|
| index 65901f86f21ff3125c9ef6d49487c411f4aa55ea..f5e11e8c811cf9f182d3446ed40bed383eff7fd2 100644
|
| --- a/fpdfsdk/src/fpdf_progressive.cpp
|
| +++ b/fpdfsdk/src/fpdf_progressive.cpp
|
| @@ -33,8 +33,6 @@ DLLEXPORT int STDCALL FPDF_RenderPageBitmap_Start(FPDF_BITMAP bitmap,
|
| if (!pPage)
|
| return FPDF_RENDER_FAILED;
|
|
|
| - // FXMT_CSLOCK_OBJ(&pPage->m_PageLock);
|
| -
|
| CRenderContext* pContext = new CRenderContext;
|
| pPage->SetPrivateData((void*)1, pContext, DropContext);
|
| #ifdef _SKIA_SUPPORT_
|
| @@ -81,8 +79,6 @@ DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page,
|
| if (!pPage)
|
| return FPDF_RENDER_FAILED;
|
|
|
| - // FXMT_CSLOCK_OBJ(&pPage->m_PageLock);
|
| -
|
| CRenderContext* pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
|
| if (pContext && pContext->m_pRenderer) {
|
| IFSDK_PAUSE_Adapter IPauseAdapter(pause);
|
| @@ -97,18 +93,17 @@ DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page,
|
| }
|
|
|
| DLLEXPORT void STDCALL FPDF_RenderPage_Close(FPDF_PAGE page) {
|
| - if (page == NULL)
|
| + if (!page)
|
| return;
|
| CPDF_Page* pPage = ((CPDFXFA_Page*)page)->GetPDFPage();
|
| if (!pPage)
|
| return;
|
|
|
| - // FXMT_CSLOCK_OBJ(&pPage->m_PageLock);
|
| -
|
| CRenderContext* pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
|
| - if (pContext) {
|
| - pContext->m_pDevice->RestoreState();
|
| - delete pContext;
|
| - pPage->RemovePrivateData((void*)1);
|
| - }
|
| + if (!pContext)
|
| + return;
|
| +
|
| + pContext->m_pDevice->RestoreState();
|
| + delete pContext;
|
| + pPage->RemovePrivateData((void*)1);
|
| }
|
|
|