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

Unified Diff: fpdfsdk/fpdfeditpage.cpp

Issue 2031653003: Get rid of NULLs in fpdfsdk/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium@nullptr_core
Patch Set: Fix bad search/replace Created 4 years, 7 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
Index: fpdfsdk/fpdfeditpage.cpp
diff --git a/fpdfsdk/fpdfeditpage.cpp b/fpdfsdk/fpdfeditpage.cpp
index 576d9fb778588789828ac81f6d189bb14bf152fa..6df639aa56ed85b33e397a28d2d234a48516b2e1 100644
--- a/fpdfsdk/fpdfeditpage.cpp
+++ b/fpdfsdk/fpdfeditpage.cpp
@@ -53,7 +53,7 @@ DLLEXPORT FPDF_DOCUMENT STDCALL FPDF_CreateNewDocument() {
}
}
- CPDF_Dictionary* pInfoDict = NULL;
+ CPDF_Dictionary* pInfoDict = nullptr;
pInfoDict = pDoc->GetInfo();
if (pInfoDict) {
if (FSDK_IsSandBoxPolicyEnabled(FPDF_POLICY_MACHINETIME_ACCESS))
@@ -84,7 +84,7 @@ DLLEXPORT FPDF_PAGE STDCALL FPDFPage_New(FPDF_DOCUMENT document,
CPDF_Dictionary* pPageDict = pDoc->CreateNewPage(page_index);
if (!pPageDict)
- return NULL;
+ return nullptr;
CPDF_Array* pMediaBoxArray = new CPDF_Array;
pMediaBoxArray->Add(new CPDF_Number(0));
pMediaBoxArray->Add(new CPDF_Number(0));
@@ -218,7 +218,7 @@ FPDFPageObj_HasTransparency(FPDF_PAGEOBJECT pageObject) {
return TRUE;
CPDF_Dictionary* pSMaskDict =
- pGeneralState ? ToDictionary(pGeneralState->m_pSoftMask) : NULL;
+ pGeneralState ? ToDictionary(pGeneralState->m_pSoftMask) : nullptr;
if (pSMaskDict)
return TRUE;
@@ -291,7 +291,7 @@ DLLEXPORT void STDCALL FPDFPage_TransformAnnots(FPDF_PAGE page,
CFX_Matrix matrix((FX_FLOAT)a, (FX_FLOAT)b, (FX_FLOAT)c, (FX_FLOAT)d,
(FX_FLOAT)e, (FX_FLOAT)f);
rect.Transform(&matrix);
- CPDF_Array* pRectArray = NULL;
+ CPDF_Array* pRectArray = nullptr;
Tom Sepez 2016/06/02 20:26:26 combine w/ next line.
Lei Zhang 2016/06/07 08:03:13 Done.
pRectArray = pAnnot->GetAnnotDict()->GetArrayBy("Rect");
if (!pRectArray)
pRectArray = new CPDF_Array;

Powered by Google App Engine
This is Rietveld 408576698