From 0d4fdc1bbf2c23999271617413f89f059d4a71c9 Mon Sep 17 00:00:00 2001 From: Bo Xu Date: Thu, 11 Dec 2014 14:24:35 -0800 Subject: Merge to XFA: patch from CL 792113003 m_pColorSpace can not be NULL for image object with DCTDecode filter BUG=411842 R=tsepez@chromium.org Review URL: https://codereview.chromium.org/792113003 --- core/src/fpdfapi/fpdf_render/fpdf_render_loadimage.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'core/src/fpdfapi/fpdf_render') diff --git a/core/src/fpdfapi/fpdf_render/fpdf_render_loadimage.cpp b/core/src/fpdfapi/fpdf_render/fpdf_render_loadimage.cpp index f053e559b3..1637655e68 100644 --- a/core/src/fpdfapi/fpdf_render/fpdf_render_loadimage.cpp +++ b/core/src/fpdfapi/fpdf_render/fpdf_render_loadimage.cpp @@ -504,6 +504,9 @@ FX_BOOL CPDF_DIBSource::LoadColorInfo(CPDF_Dictionary* pFormResources, CPDF_Dict } DIB_COMP_DATA* CPDF_DIBSource::GetDecodeAndMaskArray(FX_BOOL& bDefaultDecode, FX_BOOL& bColorKey) { + if (m_pColorSpace == NULL) { + return NULL; + } DIB_COMP_DATA* pCompData = FX_Alloc(DIB_COMP_DATA, m_nComponents); if (pCompData == NULL) { return NULL; -- cgit v1.2.3