xmloff/source/text/XMLTextCharStyleNamesElementExport.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
New commits: commit 96be3821f7dad19004a43696555eaa4fa2e1aef5 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Sun Jun 16 15:09:04 2019 +0100 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Sun Jun 16 16:56:51 2019 +0200 crashtesting: failure on export to odt of ooo33851-1.sxw since... commit 79d58ee14da8fbf636fb087453834abb7173d3fc Date: Sun May 12 16:07:58 2019 +0300 Simplify Sequence iterations in xmloff/source/{style..xforms} Use range-based loops or replace with comphelper or STL functions Change-Id: I0e00ea30a45d0ba3aa00fcb20b80fdc4931fe14d Reviewed-on: https://gerrit.libreoffice.org/74116 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/xmloff/source/text/XMLTextCharStyleNamesElementExport.cxx b/xmloff/source/text/XMLTextCharStyleNamesElementExport.cxx index 225eb6dcd246..55beb5f027f3 100644 --- a/xmloff/source/text/XMLTextCharStyleNamesElementExport.cxx +++ b/xmloff/source/text/XMLTextCharStyleNamesElementExport.cxx @@ -54,11 +54,14 @@ XMLTextCharStyleNamesElementExport::XMLTextCharStyleNamesElementExport( { aName = rExport.GetNamespaceMap().GetQNameByKey( XML_NAMESPACE_TEXT, GetXMLToken(XML_SPAN) ); - for (const auto& rName : aNames) + sal_Int32 i = nCount; + const OUString *pName = aNames.getConstArray(); + while( --i ) { rExport.AddAttribute( XML_NAMESPACE_TEXT, XML_STYLE_NAME, - rExport.EncodeStyleName( rName ) ); + rExport.EncodeStyleName( *pName ) ); rExport.StartElement( aName, false ); + ++pName; } } } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits