Kaydet (Commit) b0486259 authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz: Integer-overflow

Change-Id: Iad8ebd0861a74399f6bb4a18aecf0de735a60b61
Reviewed-on: https://gerrit.libreoffice.org/47694Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst bcf85c9c
......@@ -2019,11 +2019,15 @@ static void ParseCSS1_text_indent( const CSS1Expression *pExpr,
break;
case CSS1_PIXLENGTH:
{
long nPWidth = (long)pExpr->GetNumber();
long nPHeight = 0;
SvxCSS1Parser::PixelToTwip( nPWidth, nPHeight );
nIndent = (short)nPWidth;
bSet = true;
double fWidth = pExpr->GetNumber();
if (fWidth < SAL_MAX_INT32/2.0 && fWidth > SAL_MIN_INT32/2.0)
{
long nPWidth = (long)fWidth;
long nPHeight = 0;
SvxCSS1Parser::PixelToTwip( nPWidth, nPHeight );
nIndent = (short)nPWidth;
bSet = true;
}
}
break;
case CSS1_PERCENTAGE:
......
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