diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2026-06-24 11:12:53 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2026-06-24 11:16:34 +0000 |
| commit | 671483674edea062f2ba7d55282e7d96001fc7a2 (patch) | |
| tree | 3f217a77635cf451480cee30435f3ebe2cd4c141 | |
| parent | csi: clamp REP count to scrollback-lines * cols (diff) | |
csi: XTPUSHCOLORS: limit stack depth to 128
Closes #2362
| -rw-r--r-- | csi.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -2146,6 +2146,8 @@ csi_dispatch(struct terminal *term, uint8_t final) if (slot == 0) slot = term->color_stack.idx + 1; + slot = min(slot, 128); + if (term->color_stack.size < slot) { const size_t new_size = slot; term->color_stack.stack = xrealloc( |
