summaryrefslogtreecommitdiff
path: root/sw/source/core
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-02-11 14:02:08 +0000
committerAndras Timar <andras.timar@collabora.com>2015-02-23 10:32:53 +0100
commit4887faea7c9b530f98473eda31b0f1ee492aee23 (patch)
treefb44832456579ef46d63832fe9e80346a1b8aa04 /sw/source/core
parent0b329e0e7f1b435430ea65575ae2661a24ca4d25 (diff)
Resolves: tdf#89179 fix Undo of Numbering Level change crash
regression from long paras presumably Change-Id: Ib89169e52e42fcbe6f8e1ab0a2eb9871d38ff06d (cherry picked from commit 29d2666d92e1105473f339609ba59e54a286b71c) Reviewed-on: https://gerrit.libreoffice.org/14419 Tested-by: Michael Stahl <mstahl@redhat.com> Reviewed-by: Michael Stahl <mstahl@redhat.com> (cherry picked from commit f45183c3c652b2c023d571ef56775ce5d3b27d2a)
Diffstat (limited to 'sw/source/core')
-rw-r--r--sw/source/core/undo/unnum.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/undo/unnum.cxx b/sw/source/core/undo/unnum.cxx
index cb7e6f6f3986..27456c98a9ee 100644
--- a/sw/source/core/undo/unnum.cxx
+++ b/sw/source/core/undo/unnum.cxx
@@ -52,7 +52,7 @@ SwUndoInsNum::SwUndoInsNum( const SwPosition& rPos, const SwNumRule& rRule,
sReplaceRule( rReplaceRule ), nLRSavePos( 0 )
{
// No selection!
- nEndNode = 0, nEndCntnt = USHRT_MAX;
+ nEndNode = 0, nEndCntnt = COMPLETE_STRING;
nSttNode = rPos.nNode.GetIndex();
nSttCntnt = rPos.nContent.GetIndex();
}
@@ -224,7 +224,7 @@ void SwUndoMoveNum::UndoImpl(::sw::UndoRedoContext & rContext)
{
sal_uLong nTmpStt = nSttNode, nTmpEnd = nEndNode;
- if( nEndNode || USHRT_MAX != nEndCntnt ) // section?
+ if (nEndNode || nEndCntnt != COMPLETE_STRING) // section?
{
if( nNewStt < nSttNode ) // moved forwards
nEndNode = nEndNode - ( nSttNode - nNewStt );