summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/fpdfeditimg.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-10-13 15:17:46 -0700
committerTom Sepez <tsepez@chromium.org>2015-10-13 15:17:46 -0700
commitc8ff50435b01b765e575c93038aee08eafc7d82c (patch)
treee31c372667e4c4f1906b46ad5a281e7a6875a624 /fpdfsdk/src/fpdfeditimg.cpp
parent6eeffab789800e2afa1b9d10de70c9116db32355 (diff)
downloadpdfium-c8ff50435b01b765e575c93038aee08eafc7d82c.tar.xz
Changes to master to more closely match XFA.
These files should change in master in order to reduce the number of "noise diffs" between master and XFA as seen in https://codereview.chromium.org/1399273003/ This includes: whitespace, matching header ordering, and implementing a GetPageFromFPDFPage() from XFA. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1407583004 .
Diffstat (limited to 'fpdfsdk/src/fpdfeditimg.cpp')
-rw-r--r--fpdfsdk/src/fpdfeditimg.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/fpdfsdk/src/fpdfeditimg.cpp b/fpdfsdk/src/fpdfeditimg.cpp
index 3b5272cace..bb710789cc 100644
--- a/fpdfsdk/src/fpdfeditimg.cpp
+++ b/fpdfsdk/src/fpdfeditimg.cpp
@@ -22,7 +22,7 @@ FPDFImageObj_LoadJpegFile(FPDF_PAGE* pages,
int nCount,
FPDF_PAGEOBJECT image_object,
FPDF_FILEACCESS* fileAccess) {
- if (!image_object || !fileAccess)
+ if (!image_object || !fileAccess || !pages)
return FALSE;
IFX_FileRead* pFile = new CPDF_CustomAccess(fileAccess);
@@ -61,7 +61,7 @@ DLLEXPORT FPDF_BOOL STDCALL FPDFImageObj_SetBitmap(FPDF_PAGE* pages,
int nCount,
FPDF_PAGEOBJECT image_object,
FPDF_BITMAP bitmap) {
- if (!image_object || !bitmap)
+ if (!image_object || !bitmap || !pages)
return FALSE;
CFX_DIBitmap* pBmp = NULL;
pBmp = (CFX_DIBitmap*)bitmap;