all repos — st @ 7ceb3d1f72eabfa678e5cfae176c57630ad98c43

st (suckless terminal) config

STREscape: don't trim prematurely

STRescape holds strings in escape sequences such as OSC and DCS, and
its buffer is 512 bytes.

If the input is too big then trailing chars are ignored, but the test
was off-by-1 such that it took 510 chars instead of 511 (before a
terminating NULL is added).

Now the full size can be utilized.
Avi Halachmi (:avih) avihpit@yahoo.com
commit

7ceb3d1f72eabfa678e5cfae176c57630ad98c43

parent

ea4d933ed9d8ce16699c84892a29e070c70b2eb9

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M st.cst.c

@@ -2330,7 +2330,7 @@ }

if (term.esc&ESC_DCS && strescseq.len == 0 && u == 'q') term.mode |= MODE_SIXEL; - if (strescseq.len+len >= sizeof(strescseq.buf)-1) { + if (strescseq.len+len >= sizeof(strescseq.buf)) { /* * Here is a bug in terminals. If the user never sends * some code to stop the str or esc command, then st