Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2977)

Unified Diff: core/src/fxge/dib/fx_dib_main.cpp

Issue 1512763013: Get rid of most instance of 'foo != NULL' (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: rebase Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: core/src/fxge/dib/fx_dib_main.cpp
diff --git a/core/src/fxge/dib/fx_dib_main.cpp b/core/src/fxge/dib/fx_dib_main.cpp
index d8335f96bd36356af4b4e63ce5897ed0855e3f34..3c127b23b002fa90e365f349b6e247aaf2e09490 100644
--- a/core/src/fxge/dib/fx_dib_main.cpp
+++ b/core/src/fxge/dib/fx_dib_main.cpp
@@ -844,7 +844,6 @@ FX_BOOL CFX_DIBitmap::MultiplyAlpha(const CFX_DIBSource* pSrcBitmap) {
if (pSrcBitmap->GetWidth() != m_Width ||
pSrcBitmap->GetHeight() != m_Height) {
pSrcClone = pSrcBitmap->StretchTo(m_Width, m_Height);
- ASSERT(pSrcClone != NULL);
if (pSrcClone == NULL) {
return FALSE;
}
@@ -1340,7 +1339,7 @@ FX_BOOL CFX_DIBitmap::DitherFS(const FX_DWORD* pPalette,
if (m_pBuffer == NULL) {
return FALSE;
}
- if (m_bpp != 8 && m_pPalette != NULL && m_AlphaFlag != 0) {
+ if (m_bpp != 8 && m_pPalette && m_AlphaFlag != 0) {
return FALSE;
}
if (m_Width < 4 && m_Height < 4) {

Powered by Google App Engine
This is Rietveld 408576698