summaryrefslogtreecommitdiff
path: root/vi/v_sentence.c
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2020-10-01 04:25:54 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2020-10-01 04:25:54 +0000
commitb4ed613595432ece6802d09bfabad18e09aa26f3 (patch)
treebd2db6b09b756624c1b2babdd12ea05a9dffcdaf /vi/v_sentence.c
parent7cef6c685d23e4dcdf3f64b0b2ea92151e652db6 (diff)
Notes
Diffstat (limited to 'vi/v_sentence.c')
-rw-r--r--vi/v_sentence.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/vi/v_sentence.c b/vi/v_sentence.c
index 3415fbd18937..4ba9cfc1df33 100644
--- a/vi/v_sentence.c
+++ b/vi/v_sentence.c
@@ -336,7 +336,7 @@ okret: vp->m_stop.lno = cs.cs_lno;
* All commands move to the end of the range. Adjust the start of
* the range for motion commands.
*/
- if (ISMOTION(vp))
+ if (ISMOTION(vp)) {
if (vp->m_start.cno == 0 &&
(cs.cs_flags != 0 || vp->m_stop.cno == 0)) {
if (db_get(sp,
@@ -346,6 +346,7 @@ okret: vp->m_stop.lno = cs.cs_lno;
F_SET(vp, VM_LMODE);
} else
--vp->m_start.cno;
+ }
vp->m_final = vp->m_stop;
return (0);
}