diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-01-29 13:28:44 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-05 12:04:36 +0100 |
commit | 5c7b954935369cbbd22a6f43be63ac7c0ddbbfdc (patch) | |
tree | ac1ee3ab5e080ab65ceef2630d247d9fbe288fbb /dbaccess | |
parent | 68d9583db4226a61ba23398928b9416c5d8745c8 (diff) |
loplugin:useuniqueptr in OTable
use rtl::Reference here since these are reference counted data
structures, and we hand out references to me via our API
Change-Id: I8f69dde2db08519cb3d9de20b4ad54462e3ecc98
Reviewed-on: https://gerrit.libreoffice.org/49180
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/core/api/table.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/dbaccess/source/core/api/table.cxx b/dbaccess/source/core/api/table.cxx index 5ea0353b7e06..c2f13dcf9bdc 100644 --- a/dbaccess/source/core/api/table.cxx +++ b/dbaccess/source/core/api/table.cxx @@ -103,7 +103,7 @@ OColumn* ODBTable::createColumn(const OUString& _rName) const } else { - OColumns* pColumns = static_cast<OColumns*>(m_pColumns); + OColumns* pColumns = static_cast<OColumns*>(m_xColumns.get()); xProp.set(pColumns->createBaseObject(_rName),UNO_QUERY); } @@ -294,12 +294,12 @@ void SAL_CALL ODBTable::alterColumnByName( const OUString& _rName, const Referen if ( !getAlterService().is() ) throw SQLException(DBA_RES(RID_STR_NO_TABLE_RENAME),*this,SQLSTATE_GENERAL,1000,Any() ); - if ( !m_pColumns->hasByName(_rName) ) + if ( !m_xColumns->hasByName(_rName) ) throw SQLException(DBA_RES(RID_STR_COLUMN_NOT_VALID),*this,SQLSTATE_GENERAL,1000,Any() ); Reference<XPropertySet> xTable(this); getAlterService()->alterColumnByName(xTable,_rName,_rxDescriptor); - m_pColumns->refresh(); + m_xColumns->refresh(); } sal_Int64 SAL_CALL ODBTable::getSomething( const Sequence< sal_Int8 >& rId ) |