diff options
author | Noel Grandin <noel@peralex.com> | 2016-06-01 16:22:29 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-06-06 07:01:34 +0000 |
commit | 0323253a7c67316cb96e4a64792ab4fe74aac1ca (patch) | |
tree | 81787c4ae44ff778aa41e12574cd60a624c9277b /ucbhelper/source | |
parent | 4d666f5092d7c4f2ece9702dda4d874e44cdc6f7 (diff) |
remove some manual ref-counting
triggered when I noticed a class doing acquire() in the
constructor and then release() in the destructor.
found mostly by
git grep -n -B5 -e '->release()'
Change-Id: I96e43a3d30ffd9ae9a34275f24cd914d8f7b026f
Reviewed-on: https://gerrit.libreoffice.org/25806
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'ucbhelper/source')
-rw-r--r-- | ucbhelper/source/client/proxydecider.cxx | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/ucbhelper/source/client/proxydecider.cxx b/ucbhelper/source/client/proxydecider.cxx index 5c04d7910794..8b7630b9db17 100644 --- a/ucbhelper/source/client/proxydecider.cxx +++ b/ucbhelper/source/client/proxydecider.cxx @@ -772,19 +772,15 @@ void InternetProxyDecider_Impl::setNoProxyList( InternetProxyDecider::InternetProxyDecider( const uno::Reference< uno::XComponentContext>& rxContext ) -: m_pImpl( new proxydecider_impl::InternetProxyDecider_Impl( rxContext ) ) +: m_xImpl( new proxydecider_impl::InternetProxyDecider_Impl( rxContext ) ) { - m_pImpl->acquire(); } InternetProxyDecider::~InternetProxyDecider() { // Break circular reference between config listener and notifier. - m_pImpl->dispose(); - - // Let him go... - m_pImpl->release(); + m_xImpl->dispose(); } @@ -792,7 +788,7 @@ bool InternetProxyDecider::shouldUseProxy( const OUString & rProtocol, const OUString & rHost, sal_Int32 nPort ) const { - const InternetProxyServer & rData = m_pImpl->getProxy( rProtocol, + const InternetProxyServer & rData = m_xImpl->getProxy( rProtocol, rHost, nPort ); return !rData.aName.isEmpty(); @@ -804,7 +800,7 @@ const InternetProxyServer & InternetProxyDecider::getProxy( const OUString & rHost, sal_Int32 nPort ) const { - return m_pImpl->getProxy( rProtocol, rHost, nPort ); + return m_xImpl->getProxy( rProtocol, rHost, nPort ); } } // namespace ucbhelper |