diff options
author | Michael Stahl <mstahl@redhat.com> | 2012-07-06 22:25:44 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2012-07-06 22:34:08 +0200 |
commit | f2b6d71ccd04f41a849a0e5386f6619bfcc211da (patch) | |
tree | 97a393449d5cf766d8a43897e7b1480d91c1e61d /sw | |
parent | 3f281b6f0ad73eae72b77fa4dcab9008b7e14187 (diff) |
fdo#38071: roll back change to MarkBase::IsCoveringPosition:
This change seems wrong as the end position is actually behind the
CH_TXT_ATR_FIELDEND; fortunately it is also unnecessary because
the change in MSWordExportBase::OutputTextNode is sufficient to
fix the crash.
Change-Id: I79d508b13ecc8d85c4e09149b44695436416ba6d
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/crsr/bookmrk.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx index 211b55917938..6801d3422921 100644 --- a/sw/source/core/crsr/bookmrk.cxx +++ b/sw/source/core/crsr/bookmrk.cxx @@ -116,11 +116,12 @@ namespace sw { namespace mark } } - //We consider the CH_TXT_ATR_FIELDSTART and CH_TXT_ATR_FIELDEND - //themselves to be part of the covered range + // For fieldmarks, the CH_TXT_ATR_FIELDSTART and CH_TXT_ATR_FIELDEND + // themselves are part of the covered range. This is guaranteed by + // TextFieldmark::InitDoc/lcl_AssureFieldMarksSet. bool MarkBase::IsCoveringPosition(const SwPosition& rPos) const { - return rPos >= GetMarkStart() && rPos <= GetMarkEnd(); + return GetMarkStart() <= rPos && rPos < GetMarkEnd(); } void MarkBase::SetMarkPos(const SwPosition& rNewPos) |