[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - sc/source
Markus Mohrhard
markus.mohrhard at collabora.co.uk
Thu Jan 8 05:28:18 PST 2015
sc/source/filter/excel/xelink.cxx | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
New commits:
commit 1eb1d5a643f3526d540abe783edac78c8ded476b
Author: Markus Mohrhard <markus.mohrhard at collabora.co.uk>
Date: Mon Dec 22 06:18:07 2014 +0100
fix OOXML validation error, related fdo#40746
e.g. fdo40746-2.ods exported to OOXML
Change-Id: I48bc7a7d21ddc00eceaeb09970a2b1a60330fbf0
Reviewed-on: https://gerrit.libreoffice.org/13589
Reviewed-by: Eike Rathke <erack at redhat.com>
Tested-by: Eike Rathke <erack at redhat.com>
diff --git a/sc/source/filter/excel/xelink.cxx b/sc/source/filter/excel/xelink.cxx
index 234e65b..3de8363 100644
--- a/sc/source/filter/excel/xelink.cxx
+++ b/sc/source/filter/excel/xelink.cxx
@@ -1671,14 +1671,18 @@ void XclExpSupbook::SaveXml( XclExpXmlStream& rStrm )
FSNS(XML_r, XML_id), XclXmlUtils::ToOString( sId ).getStr(),
FSEND);
- pExternalLink->startElement( XML_sheetNames, FSEND);
- for (size_t nPos = 0, nSize = maXctList.GetSize(); nPos < nSize; ++nPos)
+ if (!maXctList.IsEmpty())
{
- pExternalLink->singleElement( XML_sheetName,
- XML_val, XclXmlUtils::ToOString( maXctList.GetRecord( nPos )->GetTabName()).getStr(),
- FSEND);
+ pExternalLink->startElement( XML_sheetNames, FSEND);
+ for (size_t nPos = 0, nSize = maXctList.GetSize(); nPos < nSize; ++nPos)
+ {
+ pExternalLink->singleElement( XML_sheetName,
+ XML_val, XclXmlUtils::ToOString( maXctList.GetRecord( nPos )->GetTabName()).getStr(),
+ FSEND);
+ }
+ pExternalLink->endElement( XML_sheetNames);
+
}
- pExternalLink->endElement( XML_sheetNames);
pExternalLink->startElement( XML_sheetDataSet, FSEND);
More information about the Libreoffice-commits
mailing list