summaryrefslogtreecommitdiff
path: root/sc/source/core
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:44:03 +0000
commit88065eebdf9bc557b2c5d982b0beacb19ef2ad36 (patch)
treea93aa6c1b2a0970f1fec2da6e8ad4a221fa52ea6 /sc/source/core
parentbfbb5906bf85f7e4134d19fbe80216c549185e69 (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/27061
Diffstat (limited to 'sc/source/core')
-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 fa9d70aeb762..143aec6f5e0e 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -3613,6 +3613,8 @@ void ScInterpreter::GetStVarParams( double& rVal, double& rValCount,
case svDouble :
{
fVal = GetDouble();
+ if ( nGlobalError )
+ return;
values.push_back(fVal);
fSum += fVal;
rValCount++;
@@ -3625,6 +3627,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++;
@@ -3652,6 +3656,11 @@ void ScInterpreter::GetStVarParams( double& rVal, double& rValCount,
}
while ((nErr == 0) && aValIter.GetNext(fVal, nErr));
}
+ if ( nErr )
+ {
+ SetError(nErr);
+ return;
+ }
}
break;
case svMatrix :