[Libreoffice-commits] .: formula/source sc/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Aug 27 13:04:11 PDT 2012
formula/source/core/api/token.cxx | 7 ++++++-
sc/source/core/tool/token.cxx | 2 ++
2 files changed, 8 insertions(+), 1 deletion(-)
New commits:
commit 0bb0937b65200382d3d8ad8f36472067ff0cbb40
Author: Eike Rathke <erack at redhat.com>
Date: Mon Aug 27 22:02:45 2012 +0200
do not silently ignore a token API error, fdo#51926 related
Change-Id: Ie187dad84bd55bb76c795b5c4807566e80349b56
diff --git a/formula/source/core/api/token.cxx b/formula/source/core/api/token.cxx
index 4649732..c18ca4f 100644
--- a/formula/source/core/api/token.cxx
+++ b/formula/source/core/api/token.cxx
@@ -328,7 +328,12 @@ bool FormulaTokenArray::Fill(const uno::Sequence< sheet::FormulaToken >& _aSeque
const sal_Int32 nCount = _aSequence.getLength();
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;
}
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index 00e17c0..c7e9367 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -1162,6 +1162,8 @@ bool ScTokenArray::AddFormulaToken(const com::sun::star::sheet::FormulaToken& _a
AddRangeName(aTokenData.Index, aTokenData.Global);
else if (eOpCode == ocDBArea)
AddDBRange(aTokenData.Index);
+ else
+ bError = true;
}
else if ( aType.equals( cppu::UnoType<sheet::ExternalReference>::get() ) )
{
More information about the Libreoffice-commits
mailing list