diff options
author | Michael Meeks <michael.meeks@novell.com> | 2011-06-07 17:52:02 +0100 |
---|---|---|
committer | Cédric Bosdonnat <cedric.bosdonnat.ooo@free.fr> | 2011-06-08 10:57:43 +0200 |
commit | aad52f69e366735844d117e508e5b44d732fe8cf (patch) | |
tree | 85993e21315a616192b1f9759138a144350c3777 | |
parent | b2f53d05d81c1da8e029b79d73b642ca28a661d1 (diff) |
fix auto-correction crash - fdo#38000
Signed-off-by: Cédric Bosdonnat <cedric.bosdonnat.ooo@free.fr>
-rw-r--r-- | editeng/source/misc/svxacorr.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index b5973a3bb1..2bf3e2fd7c 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -518,7 +518,7 @@ sal_Bool SvxAutoCorrect::FnChgOrdinalNumber( bool validNumber = true; xub_StrLen i = nEndPos; - do + while ( i > nSttPos ) { i--; bool isDigit = rCC.isDigit( rTxt, i ); @@ -531,7 +531,6 @@ sal_Bool SvxAutoCorrect::FnChgOrdinalNumber( nNumEnd = i; } } - while ( i > nSttPos ); if ( foundEnd && validNumber ) { sal_Int32 nNum = rTxt.Copy( nSttPos, nNumEnd - nSttPos + 1 ).ToInt32( ); |