diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-05-04 18:19:24 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-05-04 18:19:24 +0000 |
| commit | af9e5aef2b0fe98320d9964439d5d9dffa2d558f (patch) | |
| tree | 72c44a3d7b54911cf43173c809271fed73ce7265 /csi.c | |
| parent | term: check return value when instantiating thread synchronization primitives (diff) | |
csi: ignore invalid parameters in 'CSI Ps <space> q'
Before this patch, an invalid parameter would not change the cursor
style, but could cause the cursor to start (or stop) blinking.
Diffstat (limited to 'csi.c')
| -rw-r--r-- | csi.c | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -1452,12 +1452,18 @@ csi_dispatch(struct terminal *term, uint8_t final) case 6: /* steady bar */ term->cursor_style = CURSOR_BAR; break; + + default: + UNHANDLED(); + break; } - if (param == 0 || param & 1) - term_cursor_blink_enable(term); - else - term_cursor_blink_disable(term); + if (param <= 6) { + if (param == 0 || param & 1) + term_cursor_blink_enable(term); + else + term_cursor_blink_disable(term); + } break; } |
