diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-04-06 02:15:14 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-04-06 13:11:30 -0500 |
commit | 302bd1c4ec585011b141a167ce3f2402fcccf80c (patch) | |
tree | d71bb6b3e37e738bc41f03607bd311b7bd0ac9f0 /xmloff | |
parent | fa2d66daa6ad1f4d4c151b2990db22d3bcc57982 (diff) |
coverity#441207: Logicaly dead code
Change-Id: Ia198d64a95d86a1cd47987d6db3aa3faafba84f4
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/style/bordrhdl.cxx | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/xmloff/source/style/bordrhdl.cxx b/xmloff/source/style/bordrhdl.cxx index 41b94c926a1f..860f9a44b44c 100644 --- a/xmloff/source/style/bordrhdl.cxx +++ b/xmloff/source/style/bordrhdl.cxx @@ -222,7 +222,7 @@ bool XMLBorderHdl::importXML( const OUString& rStrImpValue, uno::Any& rValue, co } // if there is no style or a different style than none but no width, - // then the declaration is not valid. + // then the declaration is not valid. if (!bHasStyle || (table::BorderLineStyle::NONE != nStyle && !bHasWidth)) return false; @@ -237,7 +237,7 @@ bool XMLBorderHdl::importXML( const OUString& rStrImpValue, uno::Any& rValue, co } // first of all, delete an empty line - if ((bHasStyle && table::BorderLineStyle::NONE == nStyle) || + if (table::BorderLineStyle::NONE == nStyle || (bHasWidth && USHRT_MAX == nNamedWidth && 0 == nWidth) ) { aBorderLine.InnerLineWidth = 0; @@ -245,7 +245,7 @@ bool XMLBorderHdl::importXML( const OUString& rStrImpValue, uno::Any& rValue, co aBorderLine.LineDistance = 0; aBorderLine.LineWidth = 0; } - else if( bHasWidth ) + else { if( USHRT_MAX != nNamedWidth ) { @@ -257,11 +257,6 @@ bool XMLBorderHdl::importXML( const OUString& rStrImpValue, uno::Any& rValue, co lcl_frmitems_setXMLBorderStyle( aBorderLine, nStyle ); } } - else - { - aBorderLine.LineWidth = 0; - lcl_frmitems_setXMLBorderStyle( aBorderLine, nStyle ); - } // set color if( bHasColor ) |