csi: check for private marker in 'S' case

The handler for 'S' final character does not check for a private
marker. This can cause a conflict with a sequence called 'XTSMGRAPHICS'
which also has an 'S' final character, but uses the private marker '?'.
Without checking for a private marker, st will perform a scroll up
operation when XTSMGRAPHICS is seen, which can cause unexpected display
artifacts.

ref.
https://git.suckless.org/st/commit/a3f7420310be0fd778ef9fe2abf20edc2d8dc81a.html
This commit is contained in:
Bakkeby 2024-02-19 09:09:08 +01:00
parent 76cb5801f6
commit 74f19eafe9
2 changed files with 3 additions and 1 deletions

2
st.c
View file

@ -2322,6 +2322,8 @@ csihandle(void)
}
break;
case 'S': /* SU -- Scroll <n> line up */
if (csiescseq.priv)
break;
DEFAULT(csiescseq.arg[0], 1);
#if SIXEL_PATCH && SCROLLBACK_PATCH
tscrollup(term.top, csiescseq.arg[0], 1);