Kaydet (Commit) 4f957dc0 authored tarafından Norbert Thiebaud's avatar Norbert Thiebaud

coverity#735370 : signed/unsigned mixup

Change-Id: I98366335430ba5ede4e46e1e9ec6488739e2099a
üst 05a9f91d
......@@ -737,9 +737,10 @@ sal_Int32 ScVbaControl::getBackColor() throw (uno::RuntimeException)
void ScVbaControl::setBackColor( sal_Int32 nBackColor ) throw (uno::RuntimeException)
{
if ( ( nBackColor >= (sal_Int32)0x80000000 ) && ( nBackColor <= (sal_Int32)0x80000018 ) )
if ( ( (sal_uInt32)nBackColor >= (sal_uInt32)0x80000000 ) &&
( (sal_uInt32)nBackColor <= (sal_uInt32)0x80000000 + SAL_N_ELEMENTS(nSysCols) ) )
{
nBackColor = nSysCols[ nBackColor - 0x80000000 ];
nBackColor = nSysCols[ nBackColor & 0x0FF];
}
m_xProps->setPropertyValue( "BackgroundColor" , uno::makeAny( XLRGBToOORGB( nBackColor ) ) );
}
......
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