From ef3d01556e841a3a10921015cd042212e6f536ab Mon Sep 17 00:00:00 2001 From: Kim Woelders Date: Tue, 16 Oct 2018 07:46:04 +0200 Subject: [PATCH] Properly initialize termios struct before use in ttynvt_open() --- ttynvt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ttynvt.c b/ttynvt.c index 314b2e3..9814244 100644 --- a/ttynvt.c +++ b/ttynvt.c @@ -470,6 +470,8 @@ static void ttynvt_open(fuse_req_t req, struct fuse_file_info *info) tty->fds[FD_MASTER].fd = fd; tty->fds[FD_MASTER].events = POLLIN; + memset(&ios, 0, sizeof(ios)); + ios.c_iflag &= ~(IGNBRK | BRKINT | PARMRK | ISTRIP | INLCR | IGNCR | ICRNL | IXON); ios.c_oflag &= ~OPOST;