Kaydet (Commit) 7a54951f authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1231667 Unchecked return value

Change-Id: I40d8fc61b1e488955faa61c868877c7b6487c529
üst d438c470
......@@ -366,7 +366,7 @@ bool OPropertyContainerHelper::convertFastPropertyValue(
}
void OPropertyContainerHelper::setFastPropertyValue(sal_Int32 _nHandle, const Any& _rValue)
bool OPropertyContainerHelper::setFastPropertyValue(sal_Int32 _nHandle, const Any& _rValue)
{
// get the property somebody is asking for
PropertiesIterator aPos = searchHandle(_nHandle);
......@@ -375,9 +375,11 @@ void OPropertyContainerHelper::setFastPropertyValue(sal_Int32 _nHandle, const An
OSL_FAIL( "OPropertyContainerHelper::setFastPropertyValue: unknown handle!" );
// should not happen if the derived class has built a correct property set info helper to be used by
// our base class OPropertySetHelper
return;
return false;
}
bool bSuccess = true;
switch (aPos->eLocated)
{
case PropertyDescription::ltHoldMyself:
......@@ -389,11 +391,8 @@ void OPropertyContainerHelper::setFastPropertyValue(sal_Int32 _nHandle, const An
break;
case PropertyDescription::ltDerivedClassRealType:
#if OSL_DEBUG_LEVEL > 0
bool bSuccess =
#endif
// copy the data from the to-be-set value
uno_type_assignData(
bSuccess = uno_type_assignData(
aPos->aLocation.pDerivedClassMember, aPos->aProperty.Type.getTypeLibType(),
const_cast< void* >( _rValue.getValue() ), _rValue.getValueType().getTypeLibType(),
reinterpret_cast< uno_QueryInterfaceFunc >( cpp_queryInterface ),
......@@ -405,8 +404,9 @@ void OPropertyContainerHelper::setFastPropertyValue(sal_Int32 _nHandle, const An
break;
}
}
return bSuccess;
}
void OPropertyContainerHelper::getFastPropertyValue(Any& _rValue, sal_Int32 _nHandle) const
{
......
......@@ -153,7 +153,7 @@ protected:
const ::com::sun::star::uno::Any& rValue
);
void setFastPropertyValue(
bool setFastPropertyValue(
sal_Int32 nHandle,
const ::com::sun::star::uno::Any& rValue
);
......
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