summaryrefslogtreecommitdiff
path: root/sw/source/core/txtnode
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-07-03 11:31:14 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-07-06 07:04:50 +0000
commite9c3583c2cc27fc88ee81047c236ec99dd51e8de (patch)
treeb3e8394ca1ec402a31b227339366fc790124c1f8 /sw/source/core/txtnode
parent89c77994d4638c86635c70535fab6508e2f3d900 (diff)
improve the returnbyref loplugin
Change-Id: I1b510a6194282dfa4a9001d473127c5ebc8b44eb Reviewed-on: https://gerrit.libreoffice.org/16731 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sw/source/core/txtnode')
-rw-r--r--sw/source/core/txtnode/atrfld.cxx4
-rw-r--r--sw/source/core/txtnode/fntcache.cxx2
-rw-r--r--sw/source/core/txtnode/swfntcch.cxx2
3 files changed, 4 insertions, 4 deletions
diff --git a/sw/source/core/txtnode/atrfld.cxx b/sw/source/core/txtnode/atrfld.cxx
index 0a25e5921637..4445da495c54 100644
--- a/sw/source/core/txtnode/atrfld.cxx
+++ b/sw/source/core/txtnode/atrfld.cxx
@@ -402,8 +402,8 @@ void SwTextField::CopyTextField( SwTextField *pDest ) const
OSL_ENSURE( m_pTextNode, "SwTextField: where is my TextNode?" );
OSL_ENSURE( pDest->m_pTextNode, "SwTextField: where is pDest's TextNode?" );
- IDocumentFieldsAccess* pIDFA = m_pTextNode->getIDocumentFieldsAccess();
- IDocumentFieldsAccess* pDestIDFA = pDest->m_pTextNode->getIDocumentFieldsAccess();
+ IDocumentFieldsAccess* pIDFA = &m_pTextNode->getIDocumentFieldsAccess();
+ IDocumentFieldsAccess* pDestIDFA = &pDest->m_pTextNode->getIDocumentFieldsAccess();
SwFormatField& rDestFormatField = (SwFormatField&)pDest->GetFormatField();
const sal_uInt16 nFieldWhich = rDestFormatField.GetField()->GetTyp()->Which();
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index 4f458bde1653..a106cbdf1172 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -379,7 +379,7 @@ sal_uInt16 SwFntObj::GetFontLeading( const SwViewShell *pSh, const OutputDevice&
nExtLeading = 0;
}
- const IDocumentSettingAccess& rIDSA = *pSh->getIDocumentSettingAccess();
+ const IDocumentSettingAccess& rIDSA = pSh->getIDocumentSettingAccess();
const bool bBrowse = ( pSh->GetWin() &&
pSh->GetViewOptions()->getBrowseMode() &&
!pSh->GetViewOptions()->IsPrtFormat() );
diff --git a/sw/source/core/txtnode/swfntcch.cxx b/sw/source/core/txtnode/swfntcch.cxx
index e867b1dcd7ac..a21ca2414b38 100644
--- a/sw/source/core/txtnode/swfntcch.cxx
+++ b/sw/source/core/txtnode/swfntcch.cxx
@@ -31,7 +31,7 @@ SwFontCache *pSwFontCache = NULL;
SwFontObj::SwFontObj( const void *pOwn, SwViewShell *pSh ) :
SwCacheObj( pOwn ),
- aSwFont( &static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet(), pSh ? pSh->getIDocumentSettingAccess() : 0 )
+ aSwFont( &static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet(), pSh ? &pSh->getIDocumentSettingAccess() : 0 )
{
aSwFont.GoMagic( pSh, aSwFont.GetActual() );
const SwAttrSet& rAttrSet = static_cast<SwTextFormatColl const *>(pOwn)->GetAttrSet();