Kaydet (Commit) 64bb6065 authored tarafından Caolán McNamara's avatar Caolán McNamara Kaydeden (comit) Adolfo Jayme Barrientos

reject invalid tiff dimensions

Change-Id: I64e77f12cb016a7f4a9d21c732aaeaae7959da76
(cherry picked from commit 34d06214)
Reviewed-on: https://gerrit.libreoffice.org/17257Reviewed-by: 's avatarAdolfo Jayme Barrientos <fitojb@ubuntu.com>
Tested-by: 's avatarAdolfo Jayme Barrientos <fitojb@ubuntu.com>
üst 20f8d831
...@@ -1330,6 +1330,8 @@ bool TIFFReader::ReadTIFF(SvStream & rTIFF, Graphic & rGraphic ) ...@@ -1330,6 +1330,8 @@ bool TIFFReader::ReadTIFF(SvStream & rTIFF, Graphic & rGraphic )
} }
if ( !nBitsPerSample || ( nBitsPerSample > 32 ) ) if ( !nBitsPerSample || ( nBitsPerSample > 32 ) )
bStatus = false; bStatus = false;
if (nImageWidth < 0 || nImageLength < 0)
bStatus = false;
if ( bStatus ) if ( bStatus )
{ {
if ( nMaxSampleValue == 0 ) if ( nMaxSampleValue == 0 )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment