summaryrefslogtreecommitdiff
path: root/core/src/fpdfapi/fpdf_page
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-12-14 18:27:25 -0800
committerLei Zhang <thestig@chromium.org>2015-12-14 18:27:25 -0800
commit96660d6f382204339d6b1aadc3913303d436e252 (patch)
treeb5f84756e1a89251831cebc05b9d4e1f6cb2027b /core/src/fpdfapi/fpdf_page
parentd983b09c3ae29a97cba8e9ec9c6351545f6087ee (diff)
downloadpdfium-96660d6f382204339d6b1aadc3913303d436e252.tar.xz
Merge to XFA: Get rid of most instance of 'foo != NULL'
TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1512763013 . (cherry picked from commit e3c7c2b54348da4a6939f6672f6c6bff126815a7) Review URL: https://codereview.chromium.org/1529553003 .
Diffstat (limited to 'core/src/fpdfapi/fpdf_page')
-rw-r--r--core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp2
-rw-r--r--core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp
index 0bf044101c..fbe6faa471 100644
--- a/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp
+++ b/core/src/fpdfapi/fpdf_page/fpdf_page_parser_old.cpp
@@ -349,7 +349,7 @@ CPDF_Stream* CPDF_StreamParser::ReadInlineStream(CPDF_Document* pDoc,
FX_DWORD width = pDict->GetInteger("Width");
FX_DWORD height = pDict->GetInteger("Height");
FX_DWORD OrigSize = 0;
- if (pCSObj != NULL) {
+ if (pCSObj) {
FX_DWORD bpc = pDict->GetInteger("BitsPerComponent");
FX_DWORD nComponents = 1;
CPDF_ColorSpace* pCS = pDoc->LoadColorSpace(pCSObj);
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp
index e1a7493a2f..5ead9a5bea 100644
--- a/core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp
+++ b/core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp
@@ -44,7 +44,7 @@ CPDF_TilingPattern::CPDF_TilingPattern(CPDF_Document* pDoc,
m_pPatternObj = pPatternObj;
m_pDocument = pDoc;
CPDF_Dictionary* pDict = m_pPatternObj->GetDict();
- ASSERT(pDict != NULL);
+ ASSERT(pDict);
m_Pattern2Form = pDict->GetMatrix("Matrix");
m_bColored = pDict->GetInteger("PaintType") == 1;
if (parentMatrix) {
@@ -88,7 +88,7 @@ CPDF_ShadingPattern::CPDF_ShadingPattern(CPDF_Document* pDoc,
m_bShadingObj = bShading;
if (!bShading) {
CPDF_Dictionary* pDict = m_pPatternObj->GetDict();
- ASSERT(pDict != NULL);
+ ASSERT(pDict);
m_Pattern2Form = pDict->GetMatrix("Matrix");
m_pShadingObj = pDict->GetElementValue("Shading");
if (parentMatrix) {