summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorTamás Zolnai <tamas.zolnai@collabora.com>2017-10-06 18:55:27 +0200
committerAndras Timar <andras.timar@collabora.com>2017-10-07 13:01:45 +0200
commite7bdaa7113fd2b1ebd81ba392c664da8a4041bb5 (patch)
tree6344d46b7b842a2930d3b97cb410295fc6245a04 /sc
parent94109b88446b93ac2a092daf8a66986456e54725 (diff)
tdf#112936: Pivot table: LO created XLSX file makes Excel to crash
It's not actually clear, why Excel crashes, but setting the version makes it working. I expect that this version number (which specifies MSO Excel versions) makes MSO to handle the pivot table differently. As the internal implementation of the pivot table was changed in different versions. The name "DATA" might had a special meaning in the earlier versions (e.g. XP, MSO 2000) which leads this crash. So setting the version to MSO 2007 seems a good solution for this. Older versions not seems a target of LO exported XLSX files in these days. Also smaller values leads to the crash described in the bug report. Change-Id: I6e9edc949d1670d657effff9277cfd86ff163458 Reviewed-on: https://gerrit.libreoffice.org/43208 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit bab595df78bd05a45f92aa15dca058f27b86d5be) Reviewed-on: https://gerrit.libreoffice.org/43217 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/filter/excel/xepivotxml.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/sc/source/filter/excel/xepivotxml.cxx b/sc/source/filter/excel/xepivotxml.cxx
index b50182e157d8..c0932deb0377 100644
--- a/sc/source/filter/excel/xepivotxml.cxx
+++ b/sc/source/filter/excel/xepivotxml.cxx
@@ -222,6 +222,7 @@ void XclExpXmlPivotCaches::SavePivotCacheXml( XclExpXmlStream& rStrm, const Entr
FSNS(XML_xmlns, XML_r), "http://schemas.openxmlformats.org/officeDocument/2006/relationships",
FSNS(XML_r, XML_id), XclXmlUtils::ToOString(aRelId).getStr(),
XML_recordCount, OString::number(rEntry.mpCache->GetDataSize()).getStr(),
+ XML_createdVersion, "3", // MS Excel 2007, tdf#112936: setting version number makes MSO to handle the pivot table differently
FSEND);
if (rEntry.meType == Worksheet)