From 7c63b23f499069b7bbdf5e74d3e7a622918341e9 Mon Sep 17 00:00:00 2001 From: Tom Gundersen Date: Tue, 4 Nov 2014 16:13:43 +0100 Subject: shared: ptyfwd - make coverity happy Explicitly ignore return value of ioctl to set window size. Fixes CID#1250804 and CID#1250800. --- src/shared/ptyfwd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/shared/ptyfwd.c') diff --git a/src/shared/ptyfwd.c b/src/shared/ptyfwd.c index 7c6e182e5b..3f8853902a 100644 --- a/src/shared/ptyfwd.c +++ b/src/shared/ptyfwd.c @@ -280,7 +280,7 @@ static int on_sigwinch_event(sd_event_source *e, const struct signalfd_siginfo * /* The window size changed, let's forward that. */ if (ioctl(STDOUT_FILENO, TIOCGWINSZ, &ws) >= 0) - ioctl(f->master, TIOCSWINSZ, &ws); + (void)ioctl(f->master, TIOCSWINSZ, &ws); return 0; } @@ -317,7 +317,7 @@ int pty_forward_new(sd_event *event, int master, PTYForward **ret) { f->master = master; if (ioctl(STDOUT_FILENO, TIOCGWINSZ, &ws) >= 0) - ioctl(master, TIOCSWINSZ, &ws); + (void)ioctl(master, TIOCSWINSZ, &ws); if (tcgetattr(STDIN_FILENO, &f->saved_stdin_attr) >= 0) { struct termios raw_stdin_attr; -- cgit v1.2.1