diff options
author | Lei Zhang <thestig@chromium.org> | 2015-12-14 18:29:28 -0800 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-12-14 18:29:28 -0800 |
commit | e385244f8cd6ae376f6b3cf1265a0795d5d30eff (patch) | |
tree | 4bdd7c459f167ee56ae35f3b87222c2557f501f8 /core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp | |
parent | e3c7c2b54348da4a6939f6672f6c6bff126815a7 (diff) | |
download | pdfium-e385244f8cd6ae376f6b3cf1265a0795d5d30eff.tar.xz |
Get rid of most instance of 'foo == NULL'
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1520063002 .
Diffstat (limited to 'core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp')
-rw-r--r-- | core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp index 63f957a838..d8f21c692d 100644 --- a/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp +++ b/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp @@ -103,7 +103,7 @@ CPDF_Rect CPDF_ClipPath::GetClipBox() const { FX_BOOL bLayerStarted = FALSE; for (int i = 0; i < count; i++) { CPDF_TextObject* pTextObj = GetText(i); - if (pTextObj == NULL) { + if (!pTextObj) { if (!bStarted) { rect = layer_rect; bStarted = TRUE; @@ -637,7 +637,7 @@ void CPDF_ContentMarkData::AddMark(const CFX_ByteString& name, FX_BOOL bDirect) { CPDF_ContentMarkItem& item = m_Marks.Add(); item.SetName(name); - if (pDict == NULL) { + if (!pDict) { return; } item.SetParam(bDirect ? CPDF_ContentMarkItem::DirectDict @@ -652,7 +652,7 @@ void CPDF_ContentMarkData::DeleteLastMark() { m_Marks.RemoveAt(size - 1); } FX_BOOL CPDF_ContentMark::HasMark(const CFX_ByteStringC& mark) const { - if (m_pObject == NULL) { + if (!m_pObject) { return FALSE; } for (int i = 0; i < m_pObject->CountItems(); i++) { @@ -665,7 +665,7 @@ FX_BOOL CPDF_ContentMark::HasMark(const CFX_ByteStringC& mark) const { } FX_BOOL CPDF_ContentMark::LookupMark(const CFX_ByteStringC& mark, CPDF_Dictionary*& pDict) const { - if (m_pObject == NULL) { + if (!m_pObject) { return FALSE; } for (int i = 0; i < m_pObject->CountItems(); i++) { |