diff options
author | Lei Zhang <thestig@chromium.org> | 2015-12-14 18:34:00 -0800 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-12-14 18:34:00 -0800 |
commit | 412e908082a361d0fd9591eab939e96a882212f1 (patch) | |
tree | 11726052ae08f13dc5a05a82cbce870758580aeb /core/src/fxcodec/codec/fx_codec_flate.cpp | |
parent | 96660d6f382204339d6b1aadc3913303d436e252 (diff) | |
download | pdfium-412e908082a361d0fd9591eab939e96a882212f1.tar.xz |
Merge to XFA: Get rid of most instance of 'foo == NULL'
TBR=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1520063002 .
(cherry picked from commit e385244f8cd6ae376f6b3cf1265a0795d5d30eff)
Review URL: https://codereview.chromium.org/1528763003 .
Diffstat (limited to 'core/src/fxcodec/codec/fx_codec_flate.cpp')
-rw-r--r-- | core/src/fxcodec/codec/fx_codec_flate.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/src/fxcodec/codec/fx_codec_flate.cpp b/core/src/fxcodec/codec/fx_codec_flate.cpp index f9959589b3..b293781318 100644 --- a/core/src/fxcodec/codec/fx_codec_flate.cpp +++ b/core/src/fxcodec/codec/fx_codec_flate.cpp @@ -34,7 +34,7 @@ static void FPDFAPI_FlateCompress(unsigned char* dest_buf, void* FPDFAPI_FlateInit(void* (*alloc_func)(void*, unsigned int, unsigned int), void (*free_func)(void*, void*)) { z_stream* p = (z_stream*)alloc_func(0, 1, sizeof(z_stream)); - if (p == NULL) { + if (!p) { return NULL; } FXSYS_memset(p, 0, sizeof(z_stream)); @@ -835,7 +835,7 @@ FX_BOOL CCodec_FlateScanlineDecoder::v_Rewind() { FPDFAPI_FlateEnd(m_pFlate); } m_pFlate = FPDFAPI_FlateInit(my_alloc_func, my_free_func); - if (m_pFlate == NULL) { + if (!m_pFlate) { return FALSE; } FPDFAPI_FlateInput(m_pFlate, m_SrcBuf, m_SrcSize); |