aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/nvim/liveupdate.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/liveupdate.c b/src/nvim/liveupdate.c
index 9679d72569..6bff75217b 100644
--- a/src/nvim/liveupdate.c
+++ b/src/nvim/liveupdate.c
@@ -137,8 +137,8 @@ void liveupdate_send_changes(buf_T *buf, linenr_T firstline, int64_t num_added,
// the first line that changed (zero-indexed)
args.items[2] = INTEGER_OBJ(firstline - 1);
- // how many lines are being swapped out
- args.items[3] = INTEGER_OBJ(num_removed);
+ // the last line that was changed
+ args.items[3] = INTEGER_OBJ(firstline - 1 + num_removed);
// linedata of lines being swapped in
Array linedata = ARRAY_DICT_INIT;