| Index: fpdfsdk/fpdf_flatten.cpp
|
| diff --git a/fpdfsdk/fpdf_flatten.cpp b/fpdfsdk/fpdf_flatten.cpp
|
| index fe81246a0b56e401ca575e2d3f6a0dbc551a0b2b..231015201c9f5fe22b57906ad51a980d01a6abc5 100644
|
| --- a/fpdfsdk/fpdf_flatten.cpp
|
| +++ b/fpdfsdk/fpdf_flatten.cpp
|
| @@ -194,7 +194,8 @@ void SetPageContents(CFX_ByteString key,
|
| if (!pContentsObj) {
|
| // Create a new contents dictionary
|
| if (!key.IsEmpty()) {
|
| - CPDF_Stream* pNewContents = new CPDF_Stream(NULL, 0, new CPDF_Dictionary);
|
| + CPDF_Stream* pNewContents =
|
| + new CPDF_Stream(nullptr, 0, new CPDF_Dictionary);
|
| pPage->SetAtReference("Contents", pDocument,
|
| pDocument->AddIndirectObject(pNewContents));
|
|
|
| @@ -206,7 +207,7 @@ void SetPageContents(CFX_ByteString key,
|
| return;
|
| }
|
|
|
| - CPDF_Array* pContentsArray = NULL;
|
| + CPDF_Array* pContentsArray = nullptr;
|
|
|
| switch (pContentsObj->GetType()) {
|
| case CPDF_Object::STREAM: {
|
| @@ -239,7 +240,8 @@ void SetPageContents(CFX_ByteString key,
|
| pPage->SetAtReference("Contents", pDocument, dwObjNum);
|
|
|
| if (!key.IsEmpty()) {
|
| - CPDF_Stream* pNewContents = new CPDF_Stream(NULL, 0, new CPDF_Dictionary);
|
| + CPDF_Stream* pNewContents =
|
| + new CPDF_Stream(nullptr, 0, new CPDF_Dictionary);
|
| dwObjNum = pDocument->AddIndirectObject(pNewContents);
|
| pContentsArray->AddReference(pDocument, dwObjNum);
|
|
|
| @@ -376,7 +378,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) {
|
| pPageDict->SetAt("Resources", pRes);
|
| }
|
|
|
| - CPDF_Stream* pNewXObject = new CPDF_Stream(NULL, 0, new CPDF_Dictionary);
|
| + CPDF_Stream* pNewXObject = new CPDF_Stream(nullptr, 0, new CPDF_Dictionary);
|
| uint32_t dwObjNum = pDocument->AddIndirectObject(pNewXObject);
|
| CPDF_Dictionary* pPageXObject = pRes->GetDictBy("XObject");
|
| if (!pPageXObject) {
|
| @@ -399,7 +401,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) {
|
|
|
| SetPageContents(key, pPageDict, pDocument);
|
|
|
| - CPDF_Dictionary* pNewXORes = NULL;
|
| + CPDF_Dictionary* pNewXORes = nullptr;
|
|
|
| if (!key.IsEmpty()) {
|
| pPageXObject->SetAtReference(key, pDocument, dwObjNum);
|
|
|