summaryrefslogtreecommitdiff
path: root/core/fxcodec/codec/fx_codec_flate.cpp
diff options
context:
space:
mode:
authorthestig <thestig@chromium.org>2016-06-07 10:46:22 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-07 10:46:23 -0700
commit4997b22f84307521a62838f874928bf56cd3423c (patch)
treead11d99ac0a491ee222e9d0a42ec3b6ad3354e2a /core/fxcodec/codec/fx_codec_flate.cpp
parent0687e76dc259c678b3f29a6608331f07ffd8f1e2 (diff)
downloadpdfium-4997b22f84307521a62838f874928bf56cd3423c.tar.xz
Get rid of NULLs in core/
Review-Url: https://codereview.chromium.org/2032613003
Diffstat (limited to 'core/fxcodec/codec/fx_codec_flate.cpp')
-rw-r--r--core/fxcodec/codec/fx_codec_flate.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/core/fxcodec/codec/fx_codec_flate.cpp b/core/fxcodec/codec/fx_codec_flate.cpp
index cd24b6624c..d32a8a13ba 100644
--- a/core/fxcodec/codec/fx_codec_flate.cpp
+++ b/core/fxcodec/codec/fx_codec_flate.cpp
@@ -648,11 +648,11 @@ class CCodec_FlateScanlineDecoder : public CCodec_ScanlineDecoder {
};
CCodec_FlateScanlineDecoder::CCodec_FlateScanlineDecoder() {
- m_pFlate = NULL;
- m_pScanline = NULL;
- m_pLastLine = NULL;
- m_pPredictBuffer = NULL;
- m_pPredictRaw = NULL;
+ m_pFlate = nullptr;
+ m_pScanline = nullptr;
+ m_pLastLine = nullptr;
+ m_pPredictBuffer = nullptr;
+ m_pPredictRaw = nullptr;
m_LeftOver = 0;
}
CCodec_FlateScanlineDecoder::~CCodec_FlateScanlineDecoder() {
@@ -799,7 +799,7 @@ uint32_t CCodec_FlateModule::FlateOrLZWDecode(FX_BOOL bLZW,
uint32_t estimated_size,
uint8_t*& dest_buf,
uint32_t& dest_size) {
- dest_buf = NULL;
+ dest_buf = nullptr;
uint32_t offset = 0;
int predictor_type = 0;
if (predictor) {
@@ -814,7 +814,8 @@ uint32_t CCodec_FlateModule::FlateOrLZWDecode(FX_BOOL bLZW,
std::unique_ptr<CLZWDecoder> decoder(new CLZWDecoder);
dest_size = (uint32_t)-1;
offset = src_size;
- int err = decoder->Decode(NULL, dest_size, src_buf, offset, bEarlyChange);
+ int err =
+ decoder->Decode(nullptr, dest_size, src_buf, offset, bEarlyChange);
if (err || dest_size == 0 || dest_size + 1 < dest_size) {
return FX_INVALID_OFFSET;
}