coverity#982431 Division or modulo by float zero
and coverity#982432 Division or modulo by float zero Change-Id: I1b9036d85c4b31b8136a96d330d95d7b024530aa
This commit is contained in:
@@ -250,6 +250,11 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
|
||||
{
|
||||
short nXNum = 0, nXDenom = 0, nYNum = 0, nYDenom = 0;
|
||||
pWMF->ReadInt16( nYDenom ).ReadInt16( nYNum ).ReadInt16( nXDenom ).ReadInt16( nXNum );
|
||||
if (!nYDenom || !nXDenom)
|
||||
{
|
||||
pWMF->SetError( SVSTREAM_FILEFORMAT_ERROR );
|
||||
break;
|
||||
}
|
||||
pOut->ScaleDevExt( (double)nXNum / nXDenom, (double)nYNum / nYDenom );
|
||||
}
|
||||
break;
|
||||
|
Reference in New Issue
Block a user