From 08d99967dc4c4fc0ec4e2bdaa681730c6c74529c Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 6 Nov 2023 21:52:50 +0530 Subject: [PATCH] Sanitize contents of remote print --- kitty/window.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/kitty/window.py b/kitty/window.py index 071c0c061..e859d9585 100644 --- a/kitty/window.py +++ b/kitty/window.py @@ -451,10 +451,7 @@ def cmd_output(screen: Screen, which: CommandOutput = CommandOutput.last_run, as def process_remote_print(msg: memoryview) -> str: from base64 import standard_b64decode - - from .cli import green - text = standard_b64decode(msg).decode('utf-8', 'replace') - return text.replace('\x1b', green(r'\e')).replace('\a', green(r'\a')).replace('\0', green(r'\0')) + return replace_c0_codes_except_nl_space_tab(standard_b64decode(msg)).decode('utf-8', 'replace') class EdgeWidths: