summaryrefslogtreecommitdiff
path: root/connectivity/source/drivers/writer/WDriver.cxx
diff options
context:
space:
mode:
authorNoel <noel.grandin@collabora.co.uk>2021-02-22 10:48:51 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-02-22 13:37:53 +0100
commitdffe94959ada5297c7c719497395f5dfe66c4d2f (patch)
tree31df661be83710232caef059baae0ab745449056 /connectivity/source/drivers/writer/WDriver.cxx
parent2a8e84448ce2a5603f9134ee830c389dbc4fd6b6 (diff)
loplugin:refcounting in connectivity
Change-Id: Iff2f096e7ee00d9cb29d47462dd7e1963c6b06e0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111302 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'connectivity/source/drivers/writer/WDriver.cxx')
-rw-r--r--connectivity/source/drivers/writer/WDriver.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/connectivity/source/drivers/writer/WDriver.cxx b/connectivity/source/drivers/writer/WDriver.cxx
index 9bd3bc76c1e8..7c8cde2da3b7 100644
--- a/connectivity/source/drivers/writer/WDriver.cxx
+++ b/connectivity/source/drivers/writer/WDriver.cxx
@@ -61,12 +61,11 @@ uno::Reference<sdbc::XConnection>
if (!acceptsURL(url))
return nullptr;
- auto pCon = new OWriterConnection(this);
+ rtl::Reference<OWriterConnection> pCon = new OWriterConnection(this);
pCon->construct(url, info);
- uno::Reference<sdbc::XConnection> xCon = pCon;
m_xConnections.push_back(uno::WeakReferenceHelper(*pCon));
- return xCon;
+ return pCon;
}
sal_Bool SAL_CALL ODriver::acceptsURL(const OUString& url)