From 23d66e25c0ede411d00404dcc7a36e880c22e67f Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 23 Nov 2011 12:21:37 +0000 Subject: aPosArr.Remove(0, n) shouldn't be aPosArr.clear(), but aPosArr.erase(...) i.e. a0a1c3f4fb730ed3614593c3d8ddb50c23204c29 looks really dubious --- sw/source/core/docnode/ndtbl.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'sw/source') diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx index cda90ba7a1e7..242f2859f809 100644 --- a/sw/source/core/docnode/ndtbl.cxx +++ b/sw/source/core/docnode/ndtbl.cxx @@ -2971,6 +2971,7 @@ sal_Bool SwCollectTblLineBoxes::Resize( sal_uInt16 nOffset, sal_uInt16 nOldWidth if( aPosArr.size() ) { for( n = 0; n < aPosArr.size(); ++n ) + { if( aPosArr[ n ] == nOffset ) break; else if( aPosArr[ n ] > nOffset ) @@ -2979,8 +2980,9 @@ sal_Bool SwCollectTblLineBoxes::Resize( sal_uInt16 nOffset, sal_uInt16 nOldWidth --n; break; } + } - aPosArr.clear(); + aPosArr.erase(aPosArr.begin(), aPosArr.begin()+n); aBoxes.Remove( 0, n ); // dann die Positionen der neuen Size anpassen -- cgit