unix/modtermios: Fix output speed setter in tcsetattr.

The input speed was being set twice and the output speed was not set.
This commit is contained in:
Laurens Valk 2019-11-15 14:15:15 +01:00 committed by Damien George
parent 334ba01c90
commit 2679c9e116
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ STATIC mp_obj_t mod_termios_tcsetattr(mp_obj_t fd_in, mp_obj_t when_in, mp_obj_t
int res = cfsetispeed(&term, mp_obj_get_int(attrs->items[4]));
RAISE_ERRNO(res, errno);
res = cfsetispeed(&term, mp_obj_get_int(attrs->items[5]));
res = cfsetospeed(&term, mp_obj_get_int(attrs->items[5]));
RAISE_ERRNO(res, errno);
res = tcsetattr(fd, when, &term);