Set both `cfsetospeed` and `cfsetispeed`

pull/24/head
Sewci0 2024-02-17 00:21:59 +01:00 zatwierdzone przez GitHub
rodzic 241ab18b61
commit cca2dc9530
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: B5690EEEBB952194
1 zmienionych plików z 1 dodań i 0 usunięć

Wyświetl plik

@ -199,6 +199,7 @@ int openport(char *port,speed_t speed)
my_termios.c_cflag = CS8 |CREAD | CLOCAL | HUPCL;
cfmakeraw(&my_termios);
cfsetospeed(&my_termios, speed);
cfsetispeed(&my_termios, speed);
if ( tcsetattr(fd, TCSANOW, &my_termios))
{
printf("tcsetattr error %d %s\n", errno, strerror(errno));