mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-10 09:58:01 +00:00
Don't output negative numbers in the ESC[13t report.
A minus sign is illegal at that position in a control sequence, so if
ESC[13t should report something like ESC[3;-123;234t then we won't
accept it as input. Switch to printing the numbers as unsigned, so
that negative window coordinates are output as their 32-bit two's
complement; experimentation suggests that PuTTY does accept that on
input.
(cherry picked from commit 2422b18a0f
)
This commit is contained in:
parent
0db409bc07
commit
b58a34115a
@ -3995,7 +3995,9 @@ static void term_out(Terminal *term)
|
|||||||
case 13:
|
case 13:
|
||||||
if (term->ldisc) {
|
if (term->ldisc) {
|
||||||
get_window_pos(term->frontend, &x, &y);
|
get_window_pos(term->frontend, &x, &y);
|
||||||
len = sprintf(buf, "\033[3;%d;%dt", x, y);
|
len = sprintf(buf, "\033[3;%u;%ut",
|
||||||
|
(unsigned)x,
|
||||||
|
(unsigned)y);
|
||||||
ldisc_send(term->ldisc, buf, len, 0);
|
ldisc_send(term->ldisc, buf, len, 0);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user