Subject: bin/26282: ipfstat -t fails to restore termios tty state if it fails for ipf disabled
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <mmondor@gmail.com>
List: netbsd-bugs
Date: 07/14/2004 02:02:56
>Number:         26282
>Category:       bin
>Synopsis:       ipfstat -t fails to restore termios tty state if it fails for ipf disabled
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jul 14 04:28:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Matthew Mondor
>Release:        NetBSD 2.0_BETA
>Organization:
>Environment:
NetBSD ginseng.xisop 2.0_BETA NetBSD 2.0_BETA (GINSENG) #0: Sat Jun 26 09:56:57 EDT 2004  root@ginseng.xisop:/home/src/sys/arch/i386/compile/GINSENG i386
>Description:
When ipf is disabled (ipf -D state), if ipfstat is launched in top mode
(ipfstat -t), the tty termios is changed, and the executable then detects
that ipf is disabled, via a failed ioctl. When this happens, it does not
restore the original termios state, and exits. This causes the terminal
to be unbuffered and in an inconsistent state.

This probably should be fixed in ipf distribution, however
>How-To-Repeat:
ipf -D
ipfstat -t
>Fix:
Restore the termios state in the case of failed ioctl(2).
>Release-Note:
>Audit-Trail:
>Unformatted: