summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWinfried Donkers <winfrieddonkers@libreoffice.org>2016-07-06 12:48:08 +0200
committerEike Rathke <erack@redhat.com>2016-07-08 20:43:53 +0000
commitaec23208241c951e1d20515e6f8cf8ee2213cb16 (patch)
tree66744dc80d4bd3785113c8281f77e67430bdafe2
parent66a5eba473214b6d820cd5a45c58417f232d68ab (diff)
tdf#100753 propagate error with VAR and STDEV functions.
Change-Id: I1b3ece177f5586f5cd64a34d16193d01d4bd5bd9 Reviewed-on: https://gerrit.libreoffice.org/26979 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com> (cherry picked from commit b9c9bf666b4eb7ee4568fe155a2c8b50a02c4ad5) Reviewed-on: https://gerrit.libreoffice.org/27060
-rw-r--r--sc/source/core/tool/interpr1.cxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index bb1ad0e7a87a..f540da98e883 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -3629,6 +3629,8 @@ void ScInterpreter::GetStVarParams( double& rVal, double& rValCount,
case svDouble :
{
fVal = GetDouble();
+ if ( nGlobalError )
+ return;
values.push_back(fVal);
fSum += fVal;
rValCount++;
@@ -3641,6 +3643,8 @@ void ScInterpreter::GetStVarParams( double& rVal, double& rValCount,
if (aCell.hasNumeric())
{
fVal = GetCellValue(aAdr, aCell);
+ if ( nGlobalError )
+ return;
values.push_back(fVal);
fSum += fVal;
rValCount++;
@@ -3668,6 +3672,11 @@ void ScInterpreter::GetStVarParams( double& rVal, double& rValCount,
}
while ((nErr == 0) && aValIter.GetNext(fVal, nErr));
}
+ if ( nErr )
+ {
+ SetError(nErr);
+ return;
+ }
}
break;
case svMatrix :