Kaydet (Commit) e5aae767 authored tarafından Caolán McNamara's avatar Caolán McNamara Kaydeden (comit) David Tardon

exception on div by 0

Change-Id: Id33d6a5e3df5812babd28ebfc65b95ce97219ad3
(cherry picked from commit cf4159e1)
Reviewed-on: https://gerrit.libreoffice.org/17121Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarDavid Tardon <dtardon@redhat.com>
üst 927c320c
......@@ -1859,6 +1859,7 @@ sal_uLong PictReader::ReadData(sal_uInt16 nOpcode)
void PictReader::ReadPict( SvStream & rStreamPict, GDIMetaFile & rGDIMetaFile )
{
try {
sal_uInt16 nOpcode;
sal_uInt8 nOneByteOpcode;
sal_uLong nSize, nPercent, nLastPercent;
......@@ -1950,6 +1951,10 @@ void PictReader::ReadPict( SvStream & rStreamPict, GDIMetaFile & rGDIMetaFile )
pPict->SetEndian(nOrigNumberFormat);
if (pPict->GetError()) pPict->Seek(nOrigPos);
} catch (...)
{
rStreamPict.SetError(SVSTREAM_FILEFORMAT_ERROR);
}
}
namespace pict {
......
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