aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2022-07-28 16:55:34 +0000
committerDaniel Eklöf <daniel@ekloef.se>2022-07-28 16:55:34 +0000
commit24c2d568042c6fb0533071aaf72b64405ca2c324 (patch)
treef24dcb947ef4180ac4d1491aca8414ea46b8b00f
parentcsi: clamp color index for ‘CSI 38/48 ; 5 ; idx m’ sequences (diff)
render: it’s unlikely() the current cell is where the cursor is
-rw-r--r--render.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/render.c b/render.c
index 3b281a89..0dd251ae 100644
--- a/render.c
+++ b/render.c
@@ -699,7 +699,7 @@ render_cell(struct terminal *term, pixman_image_t *pix,
mtx_unlock(&term->render.workers.lock);
}
- if (has_cursor && term->cursor_style == CURSOR_BLOCK && term->kbd_focus)
+ if (unlikely(has_cursor && term->cursor_style == CURSOR_BLOCK && term->kbd_focus))
draw_cursor(term, cell, font, pix, &fg, &bg, x, y, cell_cols);
if (cell->wc == 0 || cell->wc >= CELL_SPACER || cell->wc == U'\t' ||