diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-03-08 15:05:24 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-03-08 18:54:15 +0100 |
commit | 0f0563ebd29f170f65cec749a19efdfcb4e44ba8 (patch) | |
tree | b8a90f63c5034e312348f38e934e4abeee718606 /connectivity/source/drivers | |
parent | 3d2ed830d63f0d1adcb0404ad979d5fcf9706ca2 (diff) |
loplugin:refcounting (macOS)
Change-Id: Id9c5035933453bad617d1a2f78241e435e42fe91
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112168
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'connectivity/source/drivers')
-rw-r--r-- | connectivity/source/drivers/macab/MacabResultSet.cxx | 5 | ||||
-rw-r--r-- | connectivity/source/drivers/macab/MacabStatement.cxx | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/connectivity/source/drivers/macab/MacabResultSet.cxx b/connectivity/source/drivers/macab/MacabResultSet.cxx index b35f6e2d57ca..090620af49d0 100644 --- a/connectivity/source/drivers/macab/MacabResultSet.cxx +++ b/connectivity/source/drivers/macab/MacabResultSet.cxx @@ -33,6 +33,7 @@ #include <comphelper/types.hxx> #include <connectivity/dbexception.hxx> #include <resource/sharedresources.hxx> +#include <rtl/ref.hxx> #include <strings.hrc> using namespace connectivity::macab; @@ -64,14 +65,14 @@ MacabResultSet::~MacabResultSet() void MacabResultSet::allMacabRecords() { - MacabConnection* pConnection = static_cast< MacabConnection *>(m_xStatement->getConnection().get()); + rtl::Reference<MacabConnection> pConnection = static_cast< MacabConnection *>(m_xStatement->getConnection().get()); m_aMacabRecords = pConnection->getAddressBook()->getMacabRecords(m_sTableName); } void MacabResultSet::someMacabRecords(const MacabCondition *pCondition) { - MacabConnection* pConnection = static_cast< MacabConnection *>(m_xStatement->getConnection().get()); + rtl::Reference<MacabConnection> pConnection = static_cast< MacabConnection *>(m_xStatement->getConnection().get()); MacabRecords* allRecords; allRecords = pConnection->getAddressBook()->getMacabRecords(m_sTableName); diff --git a/connectivity/source/drivers/macab/MacabStatement.cxx b/connectivity/source/drivers/macab/MacabStatement.cxx index 1b7d7f5a7bff..450213f7cca5 100644 --- a/connectivity/source/drivers/macab/MacabStatement.cxx +++ b/connectivity/source/drivers/macab/MacabStatement.cxx @@ -289,7 +289,7 @@ OUString MacabCommonStatement::getTableName() const void MacabCommonStatement::setMacabFields(MacabResultSet *pResult) const { ::rtl::Reference<connectivity::OSQLColumns> xColumns; // selected columns - MacabResultSetMetaData *pMeta; // meta information - holds the list of AddressBook fields + rtl::Reference<MacabResultSetMetaData> pMeta; // meta information - holds the list of AddressBook fields xColumns = m_aSQLIterator.getSelectColumns(); if (!xColumns.is()) |