summaryrefslogtreecommitdiff
path: root/sc/source/core/tool/interpr1.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/core/tool/interpr1.cxx')
-rw-r--r--sc/source/core/tool/interpr1.cxx11
1 files changed, 2 insertions, 9 deletions
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index da43d6e55c44..626c9b34a955 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -8263,15 +8263,8 @@ void ScInterpreter::ScSearch()
double fAnz;
if (nParamCount == 3)
{
- // This should use GetStringPositionArgument() but old versions up
- // to LibreOffice 4.2.5 allowed and ignored 0 and negative values.
- // It is unnecessary to break existing documents that "rely" on
- // that behavior. Though ODFF constrains Start to be >=1.
- /* TODO: fix this and possibly break those broken documents? */
- fAnz = rtl::math::approxFloor( GetDouble());
- if (fAnz < 1.0)
- fAnz = 1.0;
- else if (!CheckStringPositionArgument( fAnz))
+ fAnz = GetStringPositionArgument();
+ if( fAnz < 1 )
{
PushIllegalArgument();
return;