diff options
author | Noel Grandin <noel@peralex.com> | 2016-04-11 10:31:30 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-04-11 11:38:57 +0200 |
commit | f3120c0aa898eca9d28c75c037497dbf63effc2f (patch) | |
tree | 898ffee6037fa5879dce0db91937366831517c31 /connectivity/source | |
parent | f678b82f0e4dea47dfc8938f01442b6eb1ce23ad (diff) |
clang-tidy performance-unnecessary-value-param in connectivity
Change-Id: Ie84eeac24f22c5e3d3a4f63728a73023d626ccc0
Diffstat (limited to 'connectivity/source')
-rw-r--r-- | connectivity/source/commontools/dbtools.cxx | 10 | ||||
-rw-r--r-- | connectivity/source/drivers/dbase/DTable.cxx | 2 | ||||
-rw-r--r-- | connectivity/source/drivers/dbase/dindexnode.cxx | 2 | ||||
-rw-r--r-- | connectivity/source/drivers/mork/MDriver.cxx | 2 | ||||
-rw-r--r-- | connectivity/source/drivers/mork/MDriver.hxx | 2 | ||||
-rw-r--r-- | connectivity/source/drivers/mysql/YUsers.cxx | 4 | ||||
-rw-r--r-- | connectivity/source/inc/dbase/DTable.hxx | 2 | ||||
-rw-r--r-- | connectivity/source/inc/dbase/dindexnode.hxx | 2 |
8 files changed, 12 insertions, 14 deletions
diff --git a/connectivity/source/commontools/dbtools.cxx b/connectivity/source/commontools/dbtools.cxx index b859e6f26ed5..28cfb40a2b1f 100644 --- a/connectivity/source/commontools/dbtools.cxx +++ b/connectivity/source/commontools/dbtools.cxx @@ -2007,8 +2007,8 @@ void checkDisposed(bool _bThrow) throw ( DisposedException ) } -OSQLColumns::Vector::const_iterator find(OSQLColumns::Vector::const_iterator first, - OSQLColumns::Vector::const_iterator last, +OSQLColumns::Vector::const_iterator find(const OSQLColumns::Vector::const_iterator& first, + const OSQLColumns::Vector::const_iterator& last, const OUString& _rVal, const ::comphelper::UStringMixEqual& _rCase) { @@ -2016,8 +2016,8 @@ OSQLColumns::Vector::const_iterator find(OSQLColumns::Vector::const_iterator fir return find(first,last,sName,_rVal,_rCase); } -OSQLColumns::Vector::const_iterator findRealName(OSQLColumns::Vector::const_iterator first, - OSQLColumns::Vector::const_iterator last, +OSQLColumns::Vector::const_iterator findRealName(const OSQLColumns::Vector::const_iterator& first, + const OSQLColumns::Vector::const_iterator& last, const OUString& _rVal, const ::comphelper::UStringMixEqual& _rCase) { @@ -2026,7 +2026,7 @@ OSQLColumns::Vector::const_iterator findRealName(OSQLColumns::Vector::const_iter } OSQLColumns::Vector::const_iterator find(OSQLColumns::Vector::const_iterator first, - OSQLColumns::Vector::const_iterator last, + const OSQLColumns::Vector::const_iterator& last, const OUString& _rProp, const OUString& _rVal, const ::comphelper::UStringMixEqual& _rCase) diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx index 88acc9729fdc..2bee713c72de 100644 --- a/connectivity/source/drivers/dbase/DTable.cxx +++ b/connectivity/source/drivers/dbase/DTable.cxx @@ -1662,7 +1662,7 @@ static double toDouble(const OString& rString) } -bool ODbaseTable::UpdateBuffer(OValueRefVector& rRow, OValueRefRow pOrgRow, const Reference<XIndexAccess>& _xCols, const bool bForceAllFields) +bool ODbaseTable::UpdateBuffer(OValueRefVector& rRow, const OValueRefRow& pOrgRow, const Reference<XIndexAccess>& _xCols, const bool bForceAllFields) { OSL_ENSURE(m_pBuffer,"Buffer is NULL!"); if ( !m_pBuffer ) diff --git a/connectivity/source/drivers/dbase/dindexnode.cxx b/connectivity/source/drivers/dbase/dindexnode.cxx index 1697b7f9ce58..5f1501d5f4c3 100644 --- a/connectivity/source/drivers/dbase/dindexnode.cxx +++ b/connectivity/source/drivers/dbase/dindexnode.cxx @@ -479,7 +479,7 @@ ONDXNode ONDXPage::Split(ONDXPage& rPage) } -void ONDXPage::Merge(sal_uInt16 nParentNodePos, ONDXPagePtr xPage) +void ONDXPage::Merge(sal_uInt16 nParentNodePos, const ONDXPagePtr& xPage) { DBG_ASSERT(HasParent(), "kein Vater vorhanden"); DBG_ASSERT(nParentNodePos != NODE_NOTFOUND, "Falscher Indexaufbau"); diff --git a/connectivity/source/drivers/mork/MDriver.cxx b/connectivity/source/drivers/mork/MDriver.cxx index 85a17ec77542..8092c9a49977 100644 --- a/connectivity/source/drivers/mork/MDriver.cxx +++ b/connectivity/source/drivers/mork/MDriver.cxx @@ -21,7 +21,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface * SAL_CALL com_sun_star_com return cppu::acquire(new MorkDriver(context)); } -MorkDriver::MorkDriver(css::uno::Reference< css::uno::XComponentContext > const context): +MorkDriver::MorkDriver(const css::uno::Reference< css::uno::XComponentContext >& context): context_(context), m_xFactory(context_->getServiceManager(), css::uno::UNO_QUERY) { diff --git a/connectivity/source/drivers/mork/MDriver.hxx b/connectivity/source/drivers/mork/MDriver.hxx index 756495676823..198909194ec9 100644 --- a/connectivity/source/drivers/mork/MDriver.hxx +++ b/connectivity/source/drivers/mork/MDriver.hxx @@ -33,7 +33,7 @@ class MorkDriver: public cppu::WeakImplHelper< css::lang::XServiceInfo, css::sdbc::XDriver > { public: - explicit MorkDriver(css::uno::Reference< css::uno::XComponentContext > const context); + explicit MorkDriver(const css::uno::Reference< css::uno::XComponentContext >& context); static OUString getImplementationName_Static() throw(css::uno::RuntimeException); static css::uno::Sequence< OUString > getSupportedServiceNames_Static() diff --git a/connectivity/source/drivers/mysql/YUsers.cxx b/connectivity/source/drivers/mysql/YUsers.cxx index e43f540295d8..32b10fcff4a5 100644 --- a/connectivity/source/drivers/mysql/YUsers.cxx +++ b/connectivity/source/drivers/mysql/YUsers.cxx @@ -70,9 +70,7 @@ sdbcx::ObjectType OUsers::appendObject( const OUString& _rForName, const Referen { OUString aSql( "GRANT USAGE ON * TO " ); OUString aQuote = m_xConnection->getMetaData()->getIdentifierQuoteString( ); - OUString sUserName( _rForName ); - aSql += ::dbtools::quoteName(aQuote,sUserName) - + " @\"%\" "; + aSql += ::dbtools::quoteName(aQuote,_rForName) + " @\"%\" "; OUString sPassword; descriptor->getPropertyValue(OMetaConnection::getPropMap().getNameByIndex(PROPERTY_ID_PASSWORD)) >>= sPassword; if ( !sPassword.isEmpty() ) diff --git a/connectivity/source/inc/dbase/DTable.hxx b/connectivity/source/inc/dbase/DTable.hxx index ad579e8fe0da..dcfa89a031ca 100644 --- a/connectivity/source/inc/dbase/DTable.hxx +++ b/connectivity/source/inc/dbase/DTable.hxx @@ -110,7 +110,7 @@ namespace connectivity bool WriteMemo(const ORowSetValue& aVariable, sal_Size& rBlockNr); bool WriteBuffer(); - bool UpdateBuffer(OValueRefVector& rRow, OValueRefRow pOrgRow,const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xCols, bool bForceAllFields); + bool UpdateBuffer(OValueRefVector& rRow, const OValueRefRow& pOrgRow, const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess>& _xCols, bool bForceAllFields); ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet> isUniqueByColumnName(sal_Int32 _nColumnPos); bool AllocBuffer(); diff --git a/connectivity/source/inc/dbase/dindexnode.hxx b/connectivity/source/inc/dbase/dindexnode.hxx index 7f6008311e39..cc24a7c8c38b 100644 --- a/connectivity/source/inc/dbase/dindexnode.hxx +++ b/connectivity/source/inc/dbase/dindexnode.hxx @@ -141,7 +141,7 @@ namespace connectivity // Split and merge ONDXNode Split(ONDXPage& rPage); - void Merge(sal_uInt16 nParentNodePos, ONDXPagePtr xPage); + void Merge(sal_uInt16 nParentNodePos, const ONDXPagePtr& xPage); // Access operators ONDXNode& operator[] (sal_uInt16 nPos); |