From 1e96013367864e7ecbb9c03ed61a2e2f58c514c1 Mon Sep 17 00:00:00 2001 From: Martijn Dekker Date: Wed, 17 Nov 2021 23:00:46 +0100 Subject: [PATCH] tests/pty.sh: fix two failures due to typeahead on Debian Bullseye As the (original AT&T) comment at the top says, "the trickiest part of the tests is avoiding typeahead in the pty dialogue". Two tests failed to [p]eek at the prompt before they started 'typing'. This causes unpredictable results. On Debian Bullseye this triggers typeahead, which produces unwanted echo to the terminal, killing the tests. src/cmd/ksh93/tests/pty.sh: - Add missing 'p' commands for the first prompt to the tests 'nobackslashctrl in emacs' and 'emacs backslash escaping'. Resolves: https://github.com/ksh93/ksh/issues/332 --- src/cmd/ksh93/tests/pty.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/cmd/ksh93/tests/pty.sh b/src/cmd/ksh93/tests/pty.sh index 2975bb4b1..baec806e5 100755 --- a/src/cmd/ksh93/tests/pty.sh +++ b/src/cmd/ksh93/tests/pty.sh @@ -628,6 +628,7 @@ r ^:test-2: L nobackslashctrl in emacs d 15 +p :test-1: w set -o emacs --nobackslashctrl # --nobackslashctrl shouldn't be ignored by reverse search @@ -641,6 +642,7 @@ r ^:test-2: \r\n$ L emacs backslash escaping d 15 +p :test-1: w set -o emacs # Test for too many backslash deletions in reverse-search mode