summaryrefslogtreecommitdiff
path: root/core/fpdfapi/fpdf_render
diff options
context:
space:
mode:
authorWei Li <weili@chromium.org>2016-04-11 10:02:09 -0700
committerWei Li <weili@chromium.org>2016-04-11 10:02:09 -0700
commite1aebd43b0c75133f94f8b141b33d12e2e715524 (patch)
tree863aded8c706db162eb3f69d6482100f9d61b842 /core/fpdfapi/fpdf_render
parent2d4a4fc372159ac7562abea48498b6ab72c2f321 (diff)
downloadpdfium-e1aebd43b0c75133f94f8b141b33d12e2e715524.tar.xz
Use std::vector as internal storage for CPDF_Array
Replace the usage of CFX_ArrayTemplate inside CPDF_Array, which has non-standard APIs such as GetSize() returns int. R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1867183002 .
Diffstat (limited to 'core/fpdfapi/fpdf_render')
-rw-r--r--core/fpdfapi/fpdf_render/fpdf_render_image.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/fpdfapi/fpdf_render/fpdf_render_image.cpp b/core/fpdfapi/fpdf_render/fpdf_render_image.cpp
index efb55d928f..6aee8e75b6 100644
--- a/core/fpdfapi/fpdf_render/fpdf_render_image.cpp
+++ b/core/fpdfapi/fpdf_render/fpdf_render_image.cpp
@@ -417,7 +417,7 @@ FX_BOOL CPDF_ImageRenderer::StartRenderDIBSource() {
m_Flags |= FXRENDER_IMAGE_LOSSY;
}
} else if (CPDF_Array* pArray = pFilters->AsArray()) {
- for (uint32_t i = 0; i < pArray->GetCount(); i++) {
+ for (size_t i = 0; i < pArray->GetCount(); i++) {
CFX_ByteStringC bsDecodeType = pArray->GetConstStringAt(i);
if (bsDecodeType == "DCTDecode" || bsDecodeType == "JPXDecode") {
m_Flags |= FXRENDER_IMAGE_LOSSY;
@@ -937,8 +937,8 @@ CFX_DIBitmap* CPDF_RenderStatus::LoadSMask(CPDF_Dictionary* pSMaskDict,
return NULL;
}
FXSYS_memset(pFloats, 0, num_floats.ValueOrDie());
- int count = pBC->GetCount() > 8 ? 8 : pBC->GetCount();
- for (int i = 0; i < count; i++) {
+ size_t count = pBC->GetCount() > 8 ? 8 : pBC->GetCount();
+ for (size_t i = 0; i < count; i++) {
pFloats[i] = pBC->GetNumberAt(i);
}
pCS->GetRGB(pFloats, R, G, B);