aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2021-02-13 13:16:53 +0000
committerDaniel Eklöf <daniel@ekloef.se>2021-02-21 19:15:31 +0000
commit663c43c139a4cc9405dde4d0d2e4d45eeac78e92 (patch)
treea5b0e7e8ea2fb85d6bfb31acf6dd751773e6a7b3
parenturl-mode: activate_url(): ensure ‘scheme’, ‘host’ and ‘path’ are free:d (diff)
term_osc8_close(): the URL *end* column is inclusive
-rw-r--r--terminal.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/terminal.c b/terminal.c
index 9051c566..efd260f1 100644
--- a/terminal.c
+++ b/terminal.c
@@ -3047,6 +3047,12 @@ term_osc8_close(struct terminal *term)
.row = grid_row_absolute(term->grid, term->grid->cursor.point.row),
};
+ /* end is *inclusive */
+ if (--end.col < 0) {
+ end.row--;
+ end.col = term->cols - 1;
+ }
+
int r = start.row;
int start_col = start.col;
do {