download.lst                                        |    6 +++---
 jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx |   16 +++++++++++++---
 jvmfwk/source/framework.cxx                         |    8 ++++++--
 jvmfwk/source/fwkbase.cxx                           |    3 +++
 sc/inc/documentimport.hxx                           |    2 ++
 sc/source/core/data/documentimport.cxx              |   14 ++++++++++++++
 sc/source/filter/oox/sheetdatabuffer.cxx            |   16 ++++++++++++++--
 7 files changed, 55 insertions(+), 10 deletions(-)

New commits:
commit de6217f11196cfd396541675deae51403386b07d
Author:     Stephan Bergmann <[email protected]>
AuthorDate: Mon Feb 21 11:55:21 2022 +0100
Commit:     Andras Timar <[email protected]>
CommitDate: Mon Feb 21 21:45:29 2022 +0100

    Avoid unnecessary empty -Djava.class.path=
    
    Change-Id: Idcfe7321077b60381c0273910b1faeb444ef1fd8
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130242
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <[email protected]>
    (cherry picked from commit 5e8f64e50f97d39e83a3358697be14db03566878)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130266
    Reviewed-by: Caolán McNamara <[email protected]>

diff --git a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx 
b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
index 29de226211f1..e55b914edf13 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
@@ -712,17 +712,22 @@ javaPluginError jfw_plugin_startJavaVirtualMachine(
     // all versions below 1.5.1
     options.emplace_back("abort", reinterpret_cast<void*>(abort_handler));
     bool hasStackSize = false;
+#ifdef UNX
+    // Until java 1.5 we need to put a plugin.jar or javaplugin.jar (<1.4.2)
+    // in the class path in order to have applet support:
+    OString sAddPath = getPluginJarPath(pInfo->sVendor, 
pInfo->sLocation,pInfo->sVersion);
+#endif
     for (int i = 0; i < cOptions; i++)
     {
         OString opt(arOptions[i].optionString);
 #ifdef UNX
-        // Until java 1.5 we need to put a plugin.jar or javaplugin.jar 
(<1.4.2)
-        // in the class path in order to have applet support:
         if (opt.startsWith("-Djava.class.path="))
         {
-            OString sAddPath = getPluginJarPath(pInfo->sVendor, 
pInfo->sLocation,pInfo->sVersion);
             if (!sAddPath.isEmpty())
+            {
                 opt += OStringChar(SAL_PATHSEPARATOR) + sAddPath;
+                sAddPath.clear();
+            }
         }
 #endif
         if (opt == "-Xint") {
@@ -767,6 +772,11 @@ javaPluginError jfw_plugin_startJavaVirtualMachine(
         }
 #endif
     }
+#ifdef UNX
+    if (!sAddPath.isEmpty()) {
+        options.emplace_back("-Djava.class.path=" + sAddPath, nullptr);
+    }
+#endif
 
     std::unique_ptr<JavaVMOption[]> sarOptions(new 
JavaVMOption[options.size()]);
     for (std::vector<Option>::size_type i = 0; i != options.size(); ++i) {
diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx
index 200724b5483f..f71e82ef3c60 100644
--- a/jvmfwk/source/framework.cxx
+++ b/jvmfwk/source/framework.cxx
@@ -193,8 +193,12 @@ javaFrameworkError jfw_startVM(
                 //In direct mode the options are specified by bootstrap 
variables
                 //of the form UNO_JAVA_JFW_PARAMETER_1 .. 
UNO_JAVA_JFW_PARAMETER_n
                 vmParams = jfw::BootParams::getVMParameters();
-                sUserClassPath =
-                    "-Djava.class.path=" + jfw::BootParams::getClasspath();
+                auto const cp = jfw::BootParams::getClasspath();
+                if (!cp.isEmpty())
+                {
+                    sUserClassPath =
+                        "-Djava.class.path=" + cp;
+                }
             }
             else
                 OSL_ASSERT(false);
diff --git a/jvmfwk/source/fwkbase.cxx b/jvmfwk/source/fwkbase.cxx
index 0af34a443f3c..bb5df10a9c4d 100644
--- a/jvmfwk/source/fwkbase.cxx
+++ b/jvmfwk/source/fwkbase.cxx
@@ -470,6 +470,9 @@ OString makeClassPathOption(std::u16string_view 
sUserClassPath)
     }
 
     sPaths = OUStringToOString(sBufCP.makeStringAndClear(), PathEncoding());
+    if (sPaths.isEmpty()) {
+        return "";
+    }
 
     OString sOptionClassPath = "-Djava.class.path=" + sPaths;
     return sOptionClassPath;
commit 872e8fc195fb7e7fba50a204ec800fc158b31f12
Author:     Caolán McNamara <[email protected]>
AuthorDate: Wed Feb 16 11:14:48 2022 +0000
Commit:     Andras Timar <[email protected]>
CommitDate: Mon Feb 21 21:45:23 2022 +0100

    clear ScDocumentImport position cache if iterators are invalid
    
    SheetDataBuffer::finalizeArrayFormula calls
    
    ScCellRangeObj::setArrayTokens
    ScDocFunc::EnterMatrix
    ScDocument::InsertMatrixFormula
    
    and InsertMatrixFormula calls the variant of ScColumn::SetFormulaCell
    which doesn't take a sc::ColumnBlockPosition& param when SetFormulaCell
    adds a cell to the column so any iterators belonging to ScDocumentImport
    are invalid.
    
    Change-Id: Ic2814ecbeafdeb99632d2a255ed6c1dedf7376b1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130150
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <[email protected]>

diff --git a/sc/inc/documentimport.hxx b/sc/inc/documentimport.hxx
index cefe2949dcc7..0e49e073fd62 100644
--- a/sc/inc/documentimport.hxx
+++ b/sc/inc/documentimport.hxx
@@ -125,6 +125,8 @@ public:
 
     void setMergedCells(SCTAB nTab, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, 
SCROW nRow2);
 
+    void invalidateBlockPositionSet(SCTAB nTab);
+
     void finalize();
 
     /** Broadcast all formula cells that are marked with
diff --git a/sc/source/core/data/documentimport.cxx 
b/sc/source/core/data/documentimport.cxx
index ab4cb64fdcb2..d47d50a4cb35 100644
--- a/sc/source/core/data/documentimport.cxx
+++ b/sc/source/core/data/documentimport.cxx
@@ -99,6 +99,15 @@ struct ScDocumentImportImpl
         return rTab.getBlockPosition(nCol);
     }
 
+    void invalidateBlockPositionSet(SCTAB nTab)
+    {
+        if (o3tl::make_unsigned(nTab) >= maBlockPosSet.size())
+            return;
+
+        sc::TableColumnBlockPositionSet& rTab = maBlockPosSet[nTab];
+        rTab.invalidate();
+    }
+
     void initForSheets()
     {
         size_t n = mrDoc.GetTableCount();
@@ -186,6 +195,11 @@ void ScDocumentImport::setOriginDate(sal_uInt16 nYear, 
sal_uInt16 nMonth, sal_uI
     mpImpl->mrDoc.pDocOptions->SetDate(nDay, nMonth, nYear);
 }
 
+void ScDocumentImport::invalidateBlockPositionSet(SCTAB nTab)
+{
+    mpImpl->invalidateBlockPositionSet(nTab);
+}
+
 void ScDocumentImport::setAutoInput(const ScAddress& rPos, const OUString& 
rStr, const ScSetStringParam* pStringParam)
 {
     ScTable* pTab = mpImpl->mrDoc.FetchTable(rPos.Tab());
diff --git a/sc/source/filter/oox/sheetdatabuffer.cxx 
b/sc/source/filter/oox/sheetdatabuffer.cxx
index 4421c3222a17..d4d0ad87affd 100644
--- a/sc/source/filter/oox/sheetdatabuffer.cxx
+++ b/sc/source/filter/oox/sheetdatabuffer.cxx
@@ -442,9 +442,22 @@ void SheetDataBuffer::addColXfStyleProcessRowRanges()
 
 void SheetDataBuffer::finalizeImport()
 {
+    ScDocumentImport& rDocImport = getDocImport();
+
+    SCTAB nStartTabInvalidatedIters(SCTAB_MAX);
+    SCTAB nEndTabInvalidatedIters(0);
+
     // create all array formulas
     for( const auto& [rRange, rTokens] : maArrayFormulas )
-        finalizeArrayFormula( rRange, rTokens );
+    {
+        finalizeArrayFormula(rRange, rTokens);
+
+        nStartTabInvalidatedIters = std::min(rRange.aStart.Tab(), 
nStartTabInvalidatedIters);
+        nEndTabInvalidatedIters = std::max(rRange.aEnd.Tab(), 
nEndTabInvalidatedIters);
+    }
+
+    for (SCTAB nTab = nStartTabInvalidatedIters; nTab <= 
nEndTabInvalidatedIters; ++nTab)
+        rDocImport.invalidateBlockPositionSet(nTab);
 
     // create all table operations
     for( const auto& [rRange, rModel] : maTableOperations )
@@ -457,7 +470,6 @@ void SheetDataBuffer::finalizeImport()
 
     addColXfStyleProcessRowRanges();
 
-    ScDocumentImport& rDocImport = getDocImport();
     ScDocument& rDoc = rDocImport.getDoc();
     StylesBuffer& rStyles = getStyles();
     for ( const auto& [rCol, rRowStyles] : maStylesPerColumn )
commit c5de5a63f98d9d50f62a08049b7307b87e09c52e
Author:     Michael Stahl <[email protected]>
AuthorDate: Mon Feb 21 11:33:21 2022 +0100
Commit:     Andras Timar <[email protected]>
CommitDate: Mon Feb 21 21:45:16 2022 +0100

    libxml2: upgrade to release 2.9.13
    
    Fixes CVE-2022-23308
    
    Change-Id: I1b3bf5cf58d7d1f39c224b0d898176c95107fbf5
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130241
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <[email protected]>
    (cherry picked from commit d50a7151431335d1431bccef000ae39f84bdf135)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130259
    Reviewed-by: Xisco Fauli <[email protected]>

diff --git a/download.lst b/download.lst
index c046f558a34c..83c2afae8e47 100644
--- a/download.lst
+++ b/download.lst
@@ -190,9 +190,9 @@ export LIBWEBP_SHA256SUM := 
808b98d2f5b84e9b27fdef6c5372dac769c3bda4502febbfa503
 export LIBWEBP_TARBALL := libwebp-1.2.1.tar.gz
 export XMLSEC_SHA256SUM := 
26041d35a20a245ed5a2fb9ee075f10825664d274220cb5190340fa87a4d0931
 export XMLSEC_TARBALL := xmlsec1-1.2.33.tar.gz
-export LIBXML_SHA256SUM := 
c8d6681e38c56f172892c85ddc0852e1fd4b53b4209e7f4ebf17f7e2eae71d92
-export LIBXML_VERSION_MICRO := 12
-export LIBXML_TARBALL := libxml2-2.9.$(LIBXML_VERSION_MICRO).tar.gz
+export LIBXML_SHA256SUM := 
276130602d12fe484ecc03447ee5e759d0465558fbc9d6bd144e3745306ebf0e
+export LIBXML_VERSION_MICRO := 13
+export LIBXML_TARBALL := libxml2-2.9.$(LIBXML_VERSION_MICRO).tar.xz
 export LIBXSLT_SHA256SUM := 
8247f33e9a872c6ac859aa45018bc4c4d00b97e2feac9eebc10c93ce1f34dd79
 export LIBXSLT_VERSION_MICRO := 35
 export LIBXSLT_TARBALL := libxslt-1.1.$(LIBXSLT_VERSION_MICRO).tar.xz

Reply via email to