summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-09-28 12:43:28 +0200
committerMichael Stahl <mstahl@redhat.com>2016-09-28 12:52:00 +0200
commitb7192612c18222e19a0867925e4fe1d5b0e12e8a (patch)
tree6e75d78925aeccf4f4f5db4ee65fc2464787ed6d /sw
parent219aae1cea7ba88d5a4503f8070566755efd3aef (diff)
sw: presumably rEnd != rStart implies rEnd isn't on index 0
... because only checkbox marks with only one dummy character should have rEnd == rStart; the 2-dummy-character ones have the end position behind the 2nd dummy character, see lcl_AssureFieldMarksSet. ... and "fix" some more "unused variables". Change-Id: I25fb33891c1a74213bbeb2bbd7f3843809ee7273
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/crsr/bookmrk.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx
index ba6bea988309..b5364d2b7c0d 100644
--- a/sw/source/core/crsr/bookmrk.cxx
+++ b/sw/source/core/crsr/bookmrk.cxx
@@ -117,11 +117,12 @@ namespace
const SwPosition& rEnd = pField->GetMarkEnd();
SwTextNode const*const pEndTextNode = rEnd.nNode.GetNode().GetTextNode();
assert(pEndTextNode);
- const sal_Int32 nEndPos = ( rEnd == rStart || rEnd.nContent.GetIndex() == 0 )
+ const sal_Int32 nEndPos = (rEnd == rStart)
? rEnd.nContent.GetIndex()
: rEnd.nContent.GetIndex() - 1;
assert(pEndTextNode->GetText()[nEndPos] == aEndMark);
- (void) pStartTextNode;
+ (void) pEndTextNode;
+ (void) nEndPos;
SwPaM aEnd(rEnd, rEnd);
if (aEnd.Start()->nContent > 0)
--aEnd.Start()->nContent;