mirror of
https://github.com/opnsense/src.git
synced 2026-06-12 02:00:31 -04:00
termios: Do return EINVAL for bad action to tcsetattr()
Set errno for bad actions in tsetattr to catch bad actions. Sponsored by: Netflix
This commit is contained in:
parent
b2bd8c9a1d
commit
085fc4555a
1 changed files with 1 additions and 1 deletions
|
|
@ -22,7 +22,7 @@ int
|
|||
host_tcsetattr(int fd, int act, const struct host_termios *tio)
|
||||
{
|
||||
if (act < 0 || act > 2) {
|
||||
// errno = EINVAL; /* XXX ?? */
|
||||
errno = EINVAL; /* XXX ?? */
|
||||
return -1;
|
||||
}
|
||||
return host_ioctl(fd, HOST_TCSETS+act, (uintptr_t)tio);
|
||||
|
|
|
|||
Loading…
Reference in a new issue