Kaydet (Commit) 0bb0937b authored tarafından Eike Rathke's avatar Eike Rathke

do not silently ignore a token API error, fdo#51926 related

Change-Id: Ie187dad84bd55bb76c795b5c4807566e80349b56
üst 34091bc0
...@@ -328,7 +328,12 @@ bool FormulaTokenArray::Fill(const uno::Sequence< sheet::FormulaToken >& _aSeque ...@@ -328,7 +328,12 @@ bool FormulaTokenArray::Fill(const uno::Sequence< sheet::FormulaToken >& _aSeque
const sal_Int32 nCount = _aSequence.getLength(); const sal_Int32 nCount = _aSequence.getLength();
for (sal_Int32 nPos=0; nPos<nCount; nPos++) for (sal_Int32 nPos=0; nPos<nCount; nPos++)
{ {
bError |= AddFormulaToken( _aSequence[nPos] ,_pRef); bool bOneError = AddFormulaToken( _aSequence[nPos] ,_pRef);
if (bOneError)
{
AddOpCode( ocErrName); // add something that indicates an error
bError = true;
}
} }
return bError; return bError;
} }
......
...@@ -1162,6 +1162,8 @@ bool ScTokenArray::AddFormulaToken(const com::sun::star::sheet::FormulaToken& _a ...@@ -1162,6 +1162,8 @@ bool ScTokenArray::AddFormulaToken(const com::sun::star::sheet::FormulaToken& _a
AddRangeName(aTokenData.Index, aTokenData.Global); AddRangeName(aTokenData.Index, aTokenData.Global);
else if (eOpCode == ocDBArea) else if (eOpCode == ocDBArea)
AddDBRange(aTokenData.Index); AddDBRange(aTokenData.Index);
else
bError = true;
} }
else if ( aType.equals( cppu::UnoType<sheet::ExternalReference>::get() ) ) else if ( aType.equals( cppu::UnoType<sheet::ExternalReference>::get() ) )
{ {
......
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