summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-04-27 21:05:35 +0100
committerCaolán McNamara <caolanm@redhat.com>2019-04-28 15:39:46 +0200
commitf58e69e7e3f0edd53a16ea6d374e401c1284bca4 (patch)
treedc4bc797af3644c1868161a96578557d95584071 /sc
parent74bb4f6f4ccc6877de12d22d1d8badd955ed1144 (diff)
ofz#14167 arbitrary sheet limit to make fuzzing useful
Change-Id: I729d62520e9b59e96984f5d4b1aabd059f60d71d Reviewed-on: https://gerrit.libreoffice.org/71437 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/table1.cxx1
-rw-r--r--sc/source/filter/lotus/lotimpop.cxx5
2 files changed, 5 insertions, 1 deletions
diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx
index 057398906f47..2e7a7ffc33cc 100644
--- a/sc/source/core/data/table1.cxx
+++ b/sc/source/core/data/table1.cxx
@@ -278,7 +278,6 @@ ScTable::ScTable( ScDocument* pDoc, SCTAB nNewTab, const OUString& rNewName,
mbForceBreaks(false),
aDefaultColAttrArray(static_cast<SCCOL>(-1), nNewTab, pDoc, nullptr)
{
-
if (bColInfo)
{
mpColWidth.reset( new ScCompressedArray<SCCOL, sal_uInt16>( MAXCOL+1, STD_COL_WIDTH ) );
diff --git a/sc/source/filter/lotus/lotimpop.cxx b/sc/source/filter/lotus/lotimpop.cxx
index 266dc881d317..6848c6caa8b3 100644
--- a/sc/source/filter/lotus/lotimpop.cxx
+++ b/sc/source/filter/lotus/lotimpop.cxx
@@ -34,6 +34,8 @@
#include <lotattr.hxx>
#include <stringutil.hxx>
+#include <unotools/configmgr.hxx>
+
LOTUS_ROOT::LOTUS_ROOT( ScDocument* pDocP, rtl_TextEncoding eQ )
:
pDoc( pDocP),
@@ -325,6 +327,9 @@ void ImportLotus::NamedSheet()
Read(aName);
SCTAB nLTab(SanitizeTab(static_cast<SCTAB>(nTmpTab)));
+ //ofz#14167 arbitrary sheet limit to make fuzzing useful
+ if (nLTab > 5 && utl::ConfigManager::IsFuzzing())
+ nLTab = 5;
if (pD->HasTable(nLTab))
pD->RenameTab(nLTab, aName);