Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ktest.pl: Give back console on Ctrt^C on monitor

When monitoring the console output, the stdout is being redirected to do
so. If Ctrl^C is hit during this mode, the stdout is not back to the
console, the user does not see anything they type (no echo).

Add "end_monitor" to the SIGINT interrupt handler to give back the console
on Ctrl^C.

Cc: stable@vger.kernel.org
Fixes: 9f2cdcbbb90e7 ("ktest: Give console process a dedicated tty")
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>

+3
+3
tools/testing/ktest/ktest.pl
··· 4201 4201 } 4202 4202 4203 4203 sub cancel_test { 4204 + if ($monitor_cnt) { 4205 + end_monitor; 4206 + } 4204 4207 if ($email_when_canceled) { 4205 4208 my $name = get_test_name; 4206 4209 send_email("KTEST: Your [$name] test was cancelled",