This commit is contained in:
Kovid Goyal 2021-07-03 10:12:44 +05:30
parent 610a09817f
commit 38ae370202
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 2 additions and 1 deletions

View File

@ -1327,7 +1327,7 @@ static void
pending_esc_mode_char(Screen *screen, uint32_t ch, PyObject *dump_callback UNUSED) {
if (screen->parser_buf_pos > 0) {
write_pending_char(screen, ESC);
write_pending_char(screen, screen->parser_buf[screen->parser_buf_pos]);
write_pending_char(screen, screen->parser_buf[screen->parser_buf_pos - 1]);
write_pending_char(screen, ch);
SET_STATE(0);
return;

View File

@ -369,6 +369,7 @@ class TestParser(BaseTest):
pb('\033[?2026h\033[32ma\033[?2026l', ('screen_set_mode', 2026, 1), ('screen_reset_mode', 2026, 1), ('select_graphic_rendition', '32 '), ('draw', 'a'))
pb('\033[?2026h\033P+q544e\033\\ama\033P=2s\033\\',
('screen_set_mode', 2026, 1), ('screen_stop_pending_mode',), ('screen_request_capabilities', 43, '544e'), ('draw', 'ama'))
pb('\033P=1s\033\\\033(B\033P=2s\033\\', ('screen_start_pending_mode',), ('screen_stop_pending_mode',), ('screen_designate_charset', 0, 66))
s.reset()
s.set_pending_timeout(timeout)