diff options
Diffstat (limited to 'chrome/common/jpeg_codec.cc')
-rw-r--r-- | chrome/common/jpeg_codec.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/chrome/common/jpeg_codec.cc b/chrome/common/jpeg_codec.cc index 452c23d..08d5d45 100644 --- a/chrome/common/jpeg_codec.cc +++ b/chrome/common/jpeg_codec.cc @@ -514,7 +514,7 @@ SkBitmap* JPEGCodec::Decode(const unsigned char* input, size_t input_size) { SkBitmap* bitmap = new SkBitmap(); bitmap->setConfig(SkBitmap::kARGB_8888_Config, w, h); bitmap->allocPixels(); - memcpy(bitmap->getAddr32(0, 0), &data_vector[0], w * h * 4); + memcpy(bitmap->getAddr32(0, 0), &data_vector[0], data_length); return bitmap; } |