diff options
Diffstat (limited to 'libqpdf/Pl_DCT.cc')
-rw-r--r-- | libqpdf/Pl_DCT.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libqpdf/Pl_DCT.cc b/libqpdf/Pl_DCT.cc index de7e1a5e..7231486d 100644 --- a/libqpdf/Pl_DCT.cc +++ b/libqpdf/Pl_DCT.cc @@ -302,8 +302,9 @@ Pl_DCT::compress(void* cinfo_p, Buffer* b) unsigned int width = cinfo->image_width * QIntC::to_uint(cinfo->input_components); size_t expected_size = - cinfo->image_height * cinfo->image_width * - QIntC::to_uint(cinfo->input_components); + QIntC::to_size(cinfo->image_height) * + QIntC::to_size(cinfo->image_width) * + QIntC::to_size(cinfo->input_components); if (b->getSize() != expected_size) { throw std::runtime_error( |