cid#1458434 Untrusted loop bound
Change-Id: I3fd06ddf1548c1d6b5d8e91db944d2c720040718 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89873 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
This commit is contained in:
parent
b3c18cdc07
commit
43518b29fd
1 changed files with 3 additions and 0 deletions
|
@ -1078,6 +1078,9 @@ sal_uInt64 PictReader::ReadPixMapEtc( BitmapEx &rBitmap, bool bBaseAddr, bool bC
|
|||
|
||||
pBitmap.reset(new vcl::bitmap::RawBitmap( Size(nWidth, nHeight), 24 ));
|
||||
|
||||
// cid#1458434 to sanitize Untrusted loop bound
|
||||
nWidth = pBitmap->Width();
|
||||
|
||||
size_t nByteWidth = static_cast<size_t>(nWidth) * nCmpCount;
|
||||
std::vector<sal_uInt8> aScanline(nByteWidth);
|
||||
for (sal_uInt16 ny = 0; ny < nHeight; ++ny)
|
||||
|
|
Loading…
Reference in a new issue