aboutsummaryrefslogtreecommitdiff
path: root/core/fxcodec/jbig2/JBig2_GrrdProc.cpp
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-12-13 18:05:38 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-12-13 18:05:38 +0000
commite03171e52ec4232369ab3b46e11d3a0abe1eb630 (patch)
tree6a57f6a0948032e6ec387c22d8b462215e6ca1e4 /core/fxcodec/jbig2/JBig2_GrrdProc.cpp
parent8bbfdf2fca7197a0eccfef7b6fc27c590a44e7f7 (diff)
parent326d96bf5d52fdcf790b467b13f58ba3df3e81e4 (diff)
downloadpdfium-e03171e52ec4232369ab3b46e11d3a0abe1eb630.tar.gz
Change-Id: If925f85c6a039b56ff549fd5327795f57b9cd12c
Diffstat (limited to 'core/fxcodec/jbig2/JBig2_GrrdProc.cpp')
-rw-r--r--core/fxcodec/jbig2/JBig2_GrrdProc.cpp17
1 files changed, 8 insertions, 9 deletions
diff --git a/core/fxcodec/jbig2/JBig2_GrrdProc.cpp b/core/fxcodec/jbig2/JBig2_GrrdProc.cpp
index e67377622..533fb7997 100644
--- a/core/fxcodec/jbig2/JBig2_GrrdProc.cpp
+++ b/core/fxcodec/jbig2/JBig2_GrrdProc.cpp
@@ -1,4 +1,4 @@
-// Copyright 2015 PDFium Authors. All rights reserved.
+// Copyright 2015 The PDFium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -11,7 +11,6 @@
#include "core/fxcodec/jbig2/JBig2_ArithDecoder.h"
#include "core/fxcodec/jbig2/JBig2_BitStream.h"
#include "core/fxcodec/jbig2/JBig2_Image.h"
-#include "third_party/base/ptr_util.h"
CJBig2_GRRDProc::CJBig2_GRRDProc() = default;
@@ -21,7 +20,7 @@ std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::Decode(
CJBig2_ArithDecoder* pArithDecoder,
JBig2ArithCtx* grContext) {
if (!CJBig2_Image::IsValidImageSize(GRW, GRH))
- return pdfium::MakeUnique<CJBig2_Image>(GRW, GRH);
+ return std::make_unique<CJBig2_Image>(GRW, GRH);
if (!GRTEMPLATE) {
if ((GRAT[0] == -1) && (GRAT[1] == -1) && (GRAT[2] == -1) &&
@@ -41,11 +40,11 @@ std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::Decode(
std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::DecodeTemplate0Unopt(
CJBig2_ArithDecoder* pArithDecoder,
JBig2ArithCtx* grContext) {
- auto GRREG = pdfium::MakeUnique<CJBig2_Image>(GRW, GRH);
+ auto GRREG = std::make_unique<CJBig2_Image>(GRW, GRH);
if (!GRREG->data())
return nullptr;
- GRREG->Fill(0);
+ GRREG->Fill(false);
int LTP = 0;
for (uint32_t h = 0; h < GRH; h++) {
if (TPGRON) {
@@ -149,7 +148,7 @@ std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::DecodeTemplate0Opt(
int32_t iGRW = static_cast<int32_t>(GRW);
int32_t iGRH = static_cast<int32_t>(GRH);
- auto GRREG = pdfium::MakeUnique<CJBig2_Image>(iGRW, iGRH);
+ auto GRREG = std::make_unique<CJBig2_Image>(iGRW, iGRH);
if (!GRREG->data())
return nullptr;
@@ -282,11 +281,11 @@ std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::DecodeTemplate0Opt(
std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::DecodeTemplate1Unopt(
CJBig2_ArithDecoder* pArithDecoder,
JBig2ArithCtx* grContext) {
- auto GRREG = pdfium::MakeUnique<CJBig2_Image>(GRW, GRH);
+ auto GRREG = std::make_unique<CJBig2_Image>(GRW, GRH);
if (!GRREG->data())
return nullptr;
- GRREG->Fill(0);
+ GRREG->Fill(false);
int LTP = 0;
for (uint32_t h = 0; h < GRH; h++) {
if (TPGRON) {
@@ -396,7 +395,7 @@ std::unique_ptr<CJBig2_Image> CJBig2_GRRDProc::DecodeTemplate1Opt(
int32_t iGRW = static_cast<int32_t>(GRW);
int32_t iGRH = static_cast<int32_t>(GRH);
- auto GRREG = pdfium::MakeUnique<CJBig2_Image>(iGRW, iGRH);
+ auto GRREG = std::make_unique<CJBig2_Image>(iGRW, iGRH);
if (!GRREG->data())
return nullptr;