summaryrefslogtreecommitdiff
path: root/core/fpdfapi/render/cpdf_dibsource.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/render/cpdf_dibsource.cpp')
-rw-r--r--core/fpdfapi/render/cpdf_dibsource.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/fpdfapi/render/cpdf_dibsource.cpp b/core/fpdfapi/render/cpdf_dibsource.cpp
index 72dec67438..fec439a689 100644
--- a/core/fpdfapi/render/cpdf_dibsource.cpp
+++ b/core/fpdfapi/render/cpdf_dibsource.cpp
@@ -640,7 +640,7 @@ RetainPtr<CFX_DIBitmap> CPDF_DIBSource::LoadJpxBitmap() {
m_bpc < 8) {
int scale = 8 - m_bpc;
for (uint32_t row = 0; row < height; ++row) {
- uint8_t* scanline = const_cast<uint8_t*>(pCachedBitmap->GetScanline(row));
+ uint8_t* scanline = pCachedBitmap->GetWritableScanline(row);
for (uint32_t col = 0; col < width; ++col) {
*scanline = (*scanline) >> scale;
++scanline;