From: imarom Date: Mon, 20 Feb 2017 10:44:59 +0000 (+0200) Subject: TUI should skip any non-ascii chars X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=bf5ed38b39c61ac0dfc428817022ef46e3a062f6;p=trex.git TUI should skip any non-ascii chars Signed-off-by: imarom --- diff --git a/scripts/automation/trex_control_plane/stl/console/trex_tui.py b/scripts/automation/trex_control_plane/stl/console/trex_tui.py index 37ef8000..b7a235de 100644 --- a/scripts/automation/trex_control_plane/stl/console/trex_tui.py +++ b/scripts/automation/trex_control_plane/stl/console/trex_tui.py @@ -848,7 +848,7 @@ class AsyncKeys: rc = self.STATUS_NONE # fetch the stdin buffer - seq = os.read(sys.stdin.fileno(), 1024).decode() + seq = os.read(sys.stdin.fileno(), 1024).decode('ascii', errors = 'ignore') if not seq: return self.STATUS_NONE