summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2016-03-24 12:42:52 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2016-03-24 12:44:01 +0100
commit6aa836329d17bf0aca4aead6bb9c35a6783ec215 (patch)
tree022e44b0c99746e4d28476901e757c39c5c86145 /sc
parentb0a601cf48b853b0ee3ccd6aba7b9c9dc9610b7f (diff)
don't sanitize value to an insane value, tdf#97863
Change-Id: I0e4de6b676fb61536dadefc96a719cf50be128ed
Diffstat (limited to 'sc')
-rw-r--r--sc/source/filter/excel/xilink.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/filter/excel/xilink.cxx b/sc/source/filter/excel/xilink.cxx
index 96e68a1d3c15..0ffbef66cf10 100644
--- a/sc/source/filter/excel/xilink.cxx
+++ b/sc/source/filter/excel/xilink.cxx
@@ -282,7 +282,10 @@ XclImpExtName::MOper::MOper(svl::SharedStringPool& rPool, XclImpStream& rStrm) :
{
SAL_WARN("sc", "Parsing error: " << nMaxRows <<
" max possible rows, but " << nLastRow << " index claimed, truncating");
- nLastRow = nMaxRows-1;
+ if (nMaxRows > 0)
+ nLastRow = nMaxRows-1;
+ else
+ return;
}
mxCached->Resize(nLastCol+1, nLastRow+1);