sw/source/filter/html/svxcss1.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
New commits: commit 0ef0740298b45379bbf8d00d50beffee7a2f812a Author: Caolán McNamara <caol...@redhat.com> Date: Sun Jan 7 15:03:04 2018 +0000 ofz#5015 Integer-overflow Change-Id: Id5b8e3b66b5b7b0f762c72a3e66e6c425011301c Reviewed-on: https://gerrit.libreoffice.org/47534 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/sw/source/filter/html/svxcss1.cxx b/sw/source/filter/html/svxcss1.cxx index 392e02addbc0..37c0a88df992 100644 --- a/sw/source/filter/html/svxcss1.cxx +++ b/sw/source/filter/html/svxcss1.cxx @@ -2592,11 +2592,11 @@ static void ParseCSS1_border_xxx( const CSS1Expression *pExpr, bool bHori = nWhichLine == SvxBoxItemLine::TOP || nWhichLine == SvxBoxItemLine::BOTTOM; // One Pixel becomes a hairline (is prettier) - long nWidthL = (long)pExpr->GetNumber(); - if( nWidthL > 1 ) + double fWidth = pExpr->GetNumber(); + if (fWidth > 1.0 && fWidth < SAL_MAX_INT32/2.0) { - long nPWidth = bHori ? 0 : nWidthL; - long nPHeight = bHori ? nWidthL : 0; + long nPWidth = bHori ? 0 : fWidth; + long nPHeight = bHori ? fWidth : 0; SvxCSS1Parser::PixelToTwip( nPWidth, nPHeight ); nWidth = (sal_uInt16)(bHori ? nPHeight : nPWidth); }
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits