summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/fpdf_flatten.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'fpdfsdk/src/fpdf_flatten.cpp')
-rw-r--r--fpdfsdk/src/fpdf_flatten.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/fpdfsdk/src/fpdf_flatten.cpp b/fpdfsdk/src/fpdf_flatten.cpp
index 3619ef4a99..73410b6c39 100644
--- a/fpdfsdk/src/fpdf_flatten.cpp
+++ b/fpdfsdk/src/fpdf_flatten.cpp
@@ -362,12 +362,10 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) {
if (!rcOriginalMB.IsEmpty()) {
CPDF_Array* pMediaBox = new CPDF_Array();
-
pMediaBox->Add(new CPDF_Number(rcOriginalMB.left));
pMediaBox->Add(new CPDF_Number(rcOriginalMB.bottom));
pMediaBox->Add(new CPDF_Number(rcOriginalMB.right));
pMediaBox->Add(new CPDF_Number(rcOriginalMB.top));
-
pPageDict->SetAt("MediaBox", pMediaBox);
}
@@ -380,8 +378,7 @@ DLLEXPORT int STDCALL FPDFPage_Flatten(FPDF_PAGE page, int nFlag) {
pPageDict->SetAt("ArtBox", pCropBox);
}
- CPDF_Dictionary* pRes = NULL;
- pRes = pPageDict->GetDict("Resources");
+ CPDF_Dictionary* pRes = pPageDict->GetDict("Resources");
if (!pRes) {
pRes = new CPDF_Dictionary;
pPageDict->SetAt("Resources", pRes);