diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-02-26 10:02:09 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-02-26 16:50:30 +0100 |
commit | 2624a24af1425c6cb197aa316689f04efd546660 (patch) | |
tree | 96e747bea14012261b8d21cc6e60378577d21aa3 /emfio | |
parent | 34a5b1d6d87c8a35e158b96bc5d89dd427b09d64 (diff) |
ofz#6563 nBytesPerScan of 0
Change-Id: I00263d06fc06e1b4efb9938ea57d09fa5381adf8
Reviewed-on: https://gerrit.libreoffice.org/50350
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'emfio')
-rw-r--r-- | emfio/source/reader/wmfreader.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/emfio/source/reader/wmfreader.cxx b/emfio/source/reader/wmfreader.cxx index 734954a6e63e..97a7f806c764 100644 --- a/emfio/source/reader/wmfreader.cxx +++ b/emfio/source/reader/wmfreader.cxx @@ -708,7 +708,7 @@ namespace emfio Point aPoint( ReadYX() ); mpInputStream->ReadUInt16( nDontKnow ).ReadUInt16( nWidth ).ReadUInt16( nHeight ).ReadUInt16( nBytesPerScan ).ReadUChar( nPlanes ).ReadUChar( nBitCount ); - bool bOk = nWidth && nHeight && nPlanes == 1 && nBitCount == 1; + bool bOk = nWidth && nHeight && nPlanes == 1 && nBitCount == 1 && nBytesPerScan != 0; if (bOk) { bOk = nBytesPerScan <= mpInputStream->remainingSize() / nHeight; |