Date: prev next · Thread: first prev next last
2013 Archives by date, by thread · List index


Hello,

cppcheck reported this:
<error file="svx/source/accessibility/svxrectctaccessiblecontext.cxx"
line="612" id="incorrectLogicOperator" severity="style" msg="Logical
disjunction always evaluates to true: nIndex &gt;= 0 || nIndex &lt; 0."/>

Indeed we have in this file that:
    610 void SvxRectCtlAccessibleContext::checkChildIndex( long nIndex )
throw( lang::IndexOutOfBoundsException )
    611 {
    612     if( nIndex < 0 || nIndex >= getAccessibleChildCount() )
    613         throw lang::IndexOutOfBoundsException();
    614 }

and that!
    883 sal_Int32 SAL_CALL
SvxRectCtlChildAccessibleContext::getAccessibleChildCount( void ) throw(
RuntimeException )
    884 {
    885     return 0;
    886 }

And this last one is like this since 2002!

What should be done here?

Julien



--
View this message in context: 
http://nabble.documentfoundation.org/Cppcheck-incorrectLogicOperator-in-svxrectctaccessiblecontext-cxx-in-svx-module-tp4055534.html
Sent from the Dev mailing list archive at Nabble.com.

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.