connectivity/source/drivers/file/FDatabaseMetaData.cxx         |    2 +-
 connectivity/source/drivers/postgresql/pq_databasemetadata.cxx |    2 +-
 oox/source/shape/WpsContext.cxx                                |    2 +-
 sd/source/ui/func/futransf.cxx                                 |    3 +--
 svtools/source/dialogs/PlaceEditDialog.cxx                     |    2 +-
 svx/source/diagram/datamodel.cxx                               |    4 ++--
 sw/source/ui/vba/vbacontentcontrollistentries.cxx              |    2 +-
 ucb/source/cacher/cachedcontentresultset.cxx                   |    6 +++---
 8 files changed, 11 insertions(+), 12 deletions(-)

New commits:
commit a41fa46b5f2b51eb1e5a38a0c82d0beb732ead03
Author:     Caolán McNamara <caolan.mcnam...@collabora.com>
AuthorDate: Wed Aug 6 09:23:25 2025 +0100
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Wed Aug 6 12:49:19 2025 +0200

    cid#1659670 Variable copied when it could be moved
    
    and
    
    cid#1659673 Variable copied when it could be moved
    cid#1659676 Variable copied when it could be moved
    cid#1659677 Variable copied when it could be moved
    cid#1659680 Variable copied when it could be moved
    cid#1659681 Variable copied when it could be moved
    cid#1659684 Variable copied when it could be moved
    
    Change-Id: I2f56bef35f6a0a4acdfee13348f1b56c16a345f8
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188997
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>

diff --git a/connectivity/source/drivers/file/FDatabaseMetaData.cxx 
b/connectivity/source/drivers/file/FDatabaseMetaData.cxx
index efc8f8149f08..f06e7d63f5c3 100644
--- a/connectivity/source/drivers/file/FDatabaseMetaData.cxx
+++ b/connectivity/source/drivers/file/FDatabaseMetaData.cxx
@@ -419,7 +419,7 @@ Reference< XResultSet > SAL_CALL 
ODatabaseMetaData::getTablePrivileges(
                         aRow[6] = ODatabaseMetaDataResultSet::getAlterValue();
                         aRows.push_back(aRow);
                         aRow[6] = ODatabaseMetaDataResultSet::getDropValue();
-                        aRows.push_back(aRow);
+                        aRows.push_back(std::move(aRow));
                     }
                 }
             }
diff --git a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx 
b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
index 090747294c27..24a3b5a92cb4 100644
--- a/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
+++ b/connectivity/source/drivers/postgresql/pq_databasemetadata.cxx
@@ -2418,7 +2418,7 @@ css::uno::Reference< XResultSet > 
DatabaseMetaData::getIndexInfo(
                 result[R_COLUMN_NAME] <<= rowColumn->getString(2);
                 sal_Int32 nPos = static_cast<sal_Int32>(findIt - 
columns.begin() +1); // MSVC++ nonsense
                 result[R_ORDINAL_POSITION] <<= nPos;
-                vec.push_back( result );
+                vec.push_back(std::move(result));
             }
         }
     }
diff --git a/oox/source/shape/WpsContext.cxx b/oox/source/shape/WpsContext.cxx
index c60e3d8971c3..f8d249c07af2 100644
--- a/oox/source/shape/WpsContext.cxx
+++ b/oox/source/shape/WpsContext.cxx
@@ -597,7 +597,7 @@ oox::core::ContextHandlerRef 
WpsContext::onCreateContext(sal_Int32 nElementToken
             // And actually replace the shape.
             mpShapePtr = pShape;
             mpMasterShapePtr->getChildren().pop_back();
-            mpMasterShapePtr->getChildren().push_back(pShape);
+            mpMasterShapePtr->getChildren().push_back(std::move(pShape));
             return new oox::drawingml::ConnectorShapePropertiesContext(
                 *this, mpShapePtr, mpShapePtr->getConnectorShapeProperties());
         }
diff --git a/sd/source/ui/func/futransf.cxx b/sd/source/ui/func/futransf.cxx
index 452b7b72b630..0cacbe32c0b2 100644
--- a/sd/source/ui/func/futransf.cxx
+++ b/sd/source/ui/func/futransf.cxx
@@ -96,8 +96,7 @@ void FuTransform::DoExecute( SfxRequest& rReq )
         SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
         pDlg.reset(pFact->CreateCaptionDialog(mrViewShell.GetFrameWeld(), 
mpView));
 
-        const WhichRangesContainer aRange = pDlg->GetInputRanges( 
*aNewAttr.GetPool() );
-        SfxItemSet aCombSet( *aNewAttr.GetPool(), aRange );
+        SfxItemSet aCombSet(*aNewAttr.GetPool(), 
pDlg->GetInputRanges(*aNewAttr.GetPool()));
         aCombSet.Put( aNewAttr );
         aCombSet.Put( aSet );
         pDlg->SetInputSet( &aCombSet );
diff --git a/svtools/source/dialogs/PlaceEditDialog.cxx 
b/svtools/source/dialogs/PlaceEditDialog.cxx
index 781f3bffca06..c7d1ef3dc854 100644
--- a/svtools/source/dialogs/PlaceEditDialog.cxx
+++ b/svtools/source/dialogs/PlaceEditDialog.cxx
@@ -204,7 +204,7 @@ void PlaceEditDialog::InitDetails( )
 
         std::shared_ptr<DetailsContainer> 
xCmisDetails(std::make_shared<CmisDetailsContainer>(this, sUrl));
         xCmisDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
-        m_aDetailsContainers.push_back(xCmisDetails);
+        m_aDetailsContainers.push_back(std::move(xCmisDetails));
 
         ++nPos;
     }
diff --git a/svx/source/diagram/datamodel.cxx b/svx/source/diagram/datamodel.cxx
index 3f7e5864bfb1..2dc9e345a825 100644
--- a/svx/source/diagram/datamodel.cxx
+++ b/svx/source/diagram/datamodel.cxx
@@ -272,8 +272,8 @@ OUString DiagramData::addNode(const OUString& rText)
     addConnection(svx::diagram::TypeConstant::XML_presOf, 
aDataPoint.msModelId, aPresPoint.msModelId);
 
     // adding at the end, so that references are not invalidated in between
-    maPoints.push_back(aDataPoint);
-    maPoints.push_back(aPresPoint);
+    maPoints.push_back(std::move(aDataPoint));
+    maPoints.push_back(std::move(aPresPoint));
 
     return sNewNodeId;
 }
diff --git a/sw/source/ui/vba/vbacontentcontrollistentries.cxx 
b/sw/source/ui/vba/vbacontentcontrollistentries.cxx
index 8f222fe93bf2..478c3ed0b6e2 100644
--- a/sw/source/ui/vba/vbacontentcontrollistentries.cxx
+++ b/sw/source/ui/vba/vbacontentcontrollistentries.cxx
@@ -98,7 +98,7 @@ 
SwVbaContentControlListEntries::SwVbaContentControlListEntries(
           xParent, xContext,
           uno::Reference<container::XIndexAccess>(
               new ContentControlListEntryCollectionHelper(xParent, xContext, 
pCC)))
-    , m_pCC(pCC)
+    , m_pCC(std::move(pCC))
 {
 }
 
commit 7dfb235a606c85f20c380a9bae0036b296ac2dfe
Author:     Caolán McNamara <caolan.mcnam...@collabora.com>
AuthorDate: Wed Aug 6 09:13:34 2025 +0100
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Wed Aug 6 12:49:11 2025 +0200

    cid#1659628 Data race condition
    
    don't unlock guard on simple return case, so guard is always
    still locked on leaving this method
    
    Change-Id: I5c8aad5aad20280782e099cdb8a83bf434446249
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188996
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    Tested-by: Jenkins

diff --git a/ucb/source/cacher/cachedcontentresultset.cxx 
b/ucb/source/cacher/cachedcontentresultset.cxx
index 9458e8eb09fc..385e39997dfe 100644
--- a/ucb/source/cacher/cachedcontentresultset.cxx
+++ b/ucb/source/cacher/cachedcontentresultset.cxx
@@ -676,6 +676,9 @@ bool CachedContentResultSet
     }
 //  OSL_ENSURE( nRow <= m_nKnownCount, "don't step into regions you don't know 
with this method" );
 
+    if (!m_bAfterLastApplied && m_nLastAppliedPos == nRow)
+        return true;
+
     sal_Int32 nLastAppliedPos = m_nLastAppliedPos;
     bool bAfterLastApplied = m_bAfterLastApplied;
     bool bAfterLast = m_bAfterLast;
@@ -683,9 +686,6 @@ bool CachedContentResultSet
 
     rGuard.unlock();
 
-    if (!bAfterLastApplied && nLastAppliedPos == nRow)
-        return true;
-
     if( nForwardOnly == 1 )
     {
         if( bAfterLastApplied || bAfterLast || !nRow || nRow < nLastAppliedPos 
)

Reply via email to