diff options
author | Lei Zhang <thestig@chromium.org> | 2015-07-15 16:32:06 -0700 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-07-15 16:32:06 -0700 |
commit | 9f46555e0702a37287c06b07b83bb98611f0b2f0 (patch) | |
tree | 8f909dc76d1018669e59f92cf6832d1fbc99784f /core | |
parent | 6df37ed42afd7a746fb1dc50472bd1d60864b8b1 (diff) | |
download | pdfium-9f46555e0702a37287c06b07b83bb98611f0b2f0.tar.xz |
Merge to XFA: Add a null pointer check to CPDF_CalRGB::v_Load().
BUG=492055
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1241923005 .
(cherry picked from commit bf4598870df6b1ebd511d61d46bc55e1d814ce2d)
Review URL: https://codereview.chromium.org/1240843002 .
Diffstat (limited to 'core')
-rw-r--r-- | core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp index 9e6ca67041..101a197968 100644 --- a/core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp +++ b/core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp @@ -348,6 +348,9 @@ public: FX_BOOL CPDF_CalRGB::v_Load(CPDF_Document* pDoc, CPDF_Array* pArray) { CPDF_Dictionary* pDict = pArray->GetDict(1); + if (!pDict) + return FALSE; + CPDF_Array* pParam = pDict->GetArray(FX_BSTRC("WhitePoint")); int i; for (i = 0; i < 3; i ++) { |