[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - sc/source

Kohei Yoshida kohei.yoshida at collabora.com
Sat Feb 15 05:58:19 CET 2014


 sc/source/filter/xml/xmlexprt.cxx |    7 -------
 1 file changed, 7 deletions(-)

New commits:
commit 0779d3efc97a985eeedf2a45bac11afe5b11b516
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date:   Fri Feb 14 11:41:02 2014 -0500

    fdo#72390: Let's not skip auto styles from unmodified sheets.
    
    We do re-use sheet XML stream for unmodified sheets on re-save, which
    is okay.  But skipping auto style population from unmodified sheets
    is not okay because autostyles are shared across all sheets and written
    outside the sheet XML streams. Skipping styles from unmodified sheets
    could potentially fail to export used styles, not to mention could
    cause a crash as reported in the bug.
    
    Change-Id: I73e439f7354e341c2c07e28ecca5452193985860
    (cherry picked from commit 5000e64ecc55efd47d92714cf6db375ff37aac4b)
    Reviewed-on: https://gerrit.libreoffice.org/8049
    Tested-by: Markus Mohrhard <markus.mohrhard at googlemail.com>
    Reviewed-by: Markus Mohrhard <markus.mohrhard at googlemail.com>

diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 42c90fa..62c0da4 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -2532,10 +2532,6 @@ void ScXMLExport::_ExportAutoStyles()
         CollectShapesAutoStyles(nTableCount);
         for (sal_Int32 nTable = 0; nTable < nTableCount; ++nTable, IncrementProgressBar(false))
         {
-            bool bUseStream = pSheetData && pDoc && pDoc->IsStreamValid((SCTAB)nTable) &&
-                              pSheetData->HasStreamPos(nTable) && xSourceStream.is() &&
-                              !pDoc->GetChangeTrack();
-
             Reference <sheet::XSpreadsheet> xTable(xIndex->getByIndex(nTable), uno::UNO_QUERY);
             if (!xTable.is())
                 continue;
@@ -2554,9 +2550,6 @@ void ScXMLExport::_ExportAutoStyles()
                 }
             }
 
-            if (bUseStream)
-                continue;
-
             // collect other auto-styles only for non-copied sheets
             Reference<sheet::XUniqueCellFormatRangesSupplier> xCellFormatRanges ( xTable, uno::UNO_QUERY );
             if ( xCellFormatRanges.is() )


More information about the Libreoffice-commits mailing list