Fix QRasterBuffer::scanLine miscalculation with big images

scanLine is overflowing with big images. Similar change was made in
4f88475a96 to fix the same issue with
QImage::scanLine.

Fixes: QTBUG-75082
Change-Id: Ifedf28fa9a303c189dfcd12bd4ec11f438540c2e
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
This commit is contained in:
Joni Poikelin 2019-04-10 15:13:16 +03:00 committed by Jędrzej Nowacki
parent 09504d484c
commit 9bb5491c06

View File

@ -448,7 +448,7 @@ public:
void resetBuffer(int val=0);
uchar *scanLine(int y) { Q_ASSERT(y>=0); Q_ASSERT(y<m_height); return m_buffer + y * bytes_per_line; }
uchar *scanLine(int y) { Q_ASSERT(y>=0); Q_ASSERT(y<m_height); return m_buffer + y * qsizetype(bytes_per_line); }
#ifndef QT_NO_DEBUG
QImage bufferImage() const;