diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2012-10-21 16:47:37 +0200 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2012-10-21 16:47:37 +0200 |
commit | 5e56827888797f80d35ed71536b81b9854bb5ce7 (patch) | |
tree | 1cc6722e250aab2e7962c2f97af8cb0731db29b2 /sw | |
parent | 4d837ff3d0a4121216800eb88e7f48c336a5fb03 (diff) |
Fix some Variable "X" is reassigned a value before the old one has been used
Change-Id: I6df132f670c771f18b3aa7ae87b14adf266b64a4
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/ftnfrm.cxx | 3 | ||||
-rw-r--r-- | sw/source/core/layout/sectfrm.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/layout/tabfrm.cxx | 3 |
3 files changed, 4 insertions, 6 deletions
diff --git a/sw/source/core/layout/ftnfrm.cxx b/sw/source/core/layout/ftnfrm.cxx index ad5ae9e43c38..baa7be1ca7d3 100644 --- a/sw/source/core/layout/ftnfrm.cxx +++ b/sw/source/core/layout/ftnfrm.cxx @@ -795,9 +795,8 @@ SwLayoutFrm *SwFrm::GetPrevFtnLeaf( MakePageType eMakeFtn ) { //Der Vorgaenger fuer eine Fussnote ist falls moeglich der Master //in der Fussnoteneigenen Verkettung. - SwLayoutFrm *pRet = 0; SwFtnFrm *pFtn = FindFtnFrm(); - pRet = pFtn->GetMaster(); + SwLayoutFrm *pRet = pFtn->GetMaster(); SwFtnBossFrm* pOldBoss = FindFtnBossFrm(); SwPageFrm *pOldPage = pOldBoss->FindPageFrm(); diff --git a/sw/source/core/layout/sectfrm.cxx b/sw/source/core/layout/sectfrm.cxx index a0f14130a8dd..e9df7332b7a9 100644 --- a/sw/source/core/layout/sectfrm.cxx +++ b/sw/source/core/layout/sectfrm.cxx @@ -612,9 +612,9 @@ static SwCntntFrm* lcl_GetNextCntntFrm( const SwLayoutFrm* pLay, bool bFwd ) sal_Bool bGoingUp = sal_True; do { const SwFrm *p = 0; - sal_Bool bGoingFwdOrBwd = sal_False, bGoingDown = sal_False; + sal_Bool bGoingFwdOrBwd = sal_False; - bGoingDown = !bGoingUp && ( 0 != ( p = pFrm->IsLayoutFrm() ? ((SwLayoutFrm*)pFrm)->Lower() : 0 ) ); + sal_Bool bGoingDown = !bGoingUp && ( 0 != ( p = pFrm->IsLayoutFrm() ? ((SwLayoutFrm*)pFrm)->Lower() : 0 ) ); if ( !bGoingDown ) { bGoingFwdOrBwd = ( 0 != ( p = pFrm->IsFlyFrm() ? diff --git a/sw/source/core/layout/tabfrm.cxx b/sw/source/core/layout/tabfrm.cxx index 57b880113787..af3373a65106 100644 --- a/sw/source/core/layout/tabfrm.cxx +++ b/sw/source/core/layout/tabfrm.cxx @@ -5524,10 +5524,9 @@ SwTwips SwTabFrm::CalcHeightOfFirstContentLine() const return (Frm().*fnRect->fnGetHeight)(); } - SwRowFrm* pFirstRow = 0; SwTwips nTmpHeight = 0; - pFirstRow = GetFirstNonHeadlineRow(); + SwRowFrm* pFirstRow = GetFirstNonHeadlineRow(); OSL_ENSURE( !IsFollow() || pFirstRow, "FollowTable without Lower" ); // NEW TABLES |