summaryrefslogtreecommitdiff
path: root/core/src/fxcodec/jbig2/JBig2_Image.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-11-24 11:47:24 -0800
committerLei Zhang <thestig@chromium.org>2015-11-24 11:47:24 -0800
commitb599f192d635d97a2f41e8ffc9784e5291b11caf (patch)
treed324317c0c826757a715a0b45c61aa82a24f019c /core/src/fxcodec/jbig2/JBig2_Image.cpp
parent5259ef39ae47831a3533f475234b30f22a2ca849 (diff)
downloadpdfium-b599f192d635d97a2f41e8ffc9784e5291b11caf.tar.xz
Merge to XFA: Fix a NULL pointer crash in the CJBig2_Image copy constructor.
Also change the copy ctor to take a const ref. BUG=560520 TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1472113002 . (cherry picked from commit d03bc01003ae2603dafdc07b901ffef0a509a2b9) Review URL: https://codereview.chromium.org/1478473002 .
Diffstat (limited to 'core/src/fxcodec/jbig2/JBig2_Image.cpp')
-rw-r--r--core/src/fxcodec/jbig2/JBig2_Image.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/fxcodec/jbig2/JBig2_Image.cpp b/core/src/fxcodec/jbig2/JBig2_Image.cpp
index a2a0acfe95..074458744d 100644
--- a/core/src/fxcodec/jbig2/JBig2_Image.cpp
+++ b/core/src/fxcodec/jbig2/JBig2_Image.cpp
@@ -36,7 +36,7 @@ CJBig2_Image::CJBig2_Image(int32_t w,
m_pData = pBuf;
m_bNeedFree = FALSE;
}
-CJBig2_Image::CJBig2_Image(CJBig2_Image& im) {
+CJBig2_Image::CJBig2_Image(const CJBig2_Image& im) {
m_nWidth = im.m_nWidth;
m_nHeight = im.m_nHeight;
m_nStride = im.m_nStride;