Hello,

Cppcheck reported this:
vcl/source/gdi/impimage.cxx
300     multiCondition  style   Expression is always false because 'else if'
condition matches previous condition at line 298.

Indeed we have:
    296                 else
    297                 {
    298                     if( aTmpBmpEx.IsAlpha() )
    299                         aTmpBmpEx = BitmapEx( aTmpBmp,
aTmpBmpEx.GetAlpha() );
    300                     else if( aTmpBmpEx.IsAlpha() )
    301                         aTmpBmpEx = BitmapEx( aTmpBmp,
aTmpBmpEx.GetMask() );
    302                 }
see
http://opengrok.libreoffice.org/xref/core/vcl/source/gdi/impimage.cxx#298

Should the else if be:
else if( aTmpBmpEx.IsTransparent())
?

Julien




--
View this message in context: 
http://nabble.documentfoundation.org/Cppcheck-reports-else-if-condition-matches-previous-condition-vcl-tp4104270.html
Sent from the Dev mailing list archive at Nabble.com.
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to