From 00a09d78ea7ee2180d32280c9157677fef8d204c Mon Sep 17 00:00:00 2001 From: Soumendra Ganguly Date: Fri, 17 Jul 2020 04:54:30 -0500 Subject: [PATCH] scriptreplay: enable special character handling Calling cfmakeraw disables terminal special character handling. For example, Ctrl-C does not send SIGINT to scriptreplay. The following fixes this. tattr.c_lflag |= ISIG; where tattr is the struct termios with which we are working. --- term-utils/scriptreplay.c | 1 + 1 file changed, 1 insertion(+) diff --git a/term-utils/scriptreplay.c b/term-utils/scriptreplay.c index 19a7d568b..99edcaf8d 100644 --- a/term-utils/scriptreplay.c +++ b/term-utils/scriptreplay.c @@ -130,6 +130,7 @@ static int termraw(struct termios *backup) tattr = *backup; cfmakeraw(&tattr); + tattr.c_lflag |= ISIG; if (tcsetattr(STDOUT_FILENO, TCSANOW, &tattr) != 0) return -1;