Ignore DSR/DTR flow control in DCB. termios doesn't support it.

This commit is contained in:
Mike McCormack 2001-11-07 20:13:25 +00:00 committed by Alexandre Julliard
parent aafec98803
commit 37f61c45de
1 changed files with 7 additions and 6 deletions

View File

@ -1061,14 +1061,13 @@ BOOL WINAPI SetCommState(
port.c_cflag |= CRTSCTS;
TRACE("CRTSCTS\n");
}
#endif
if (lpdcb->fDtrControl == DTR_CONTROL_ENABLE)
{
port.c_cflag &= ~CRTSCTS;
TRACE("~CRTSCTS\n");
WARN("DSR/DTR flow control not supported\n");
}
#endif
if (lpdcb->fInX)
port.c_iflag |= IXON;
else
@ -1243,18 +1242,20 @@ BOOL WINAPI GetCommState(
lpdcb->fNull = 0;
lpdcb->fBinary = 1;
/* termios does not support DTR/DSR flow control */
lpdcb->fOutxDsrFlow = 0;
lpdcb->fDtrControl = DTR_CONTROL_DISABLE;
#ifdef CRTSCTS
if (port.c_cflag & CRTSCTS) {
lpdcb->fDtrControl = DTR_CONTROL_ENABLE;
lpdcb->fRtsControl = RTS_CONTROL_ENABLE;
lpdcb->fOutxCtsFlow = 1;
lpdcb->fOutxDsrFlow = 1;
} else
#endif
{
lpdcb->fDtrControl = DTR_CONTROL_DISABLE;
lpdcb->fRtsControl = RTS_CONTROL_DISABLE;
lpdcb->fOutxCtsFlow = 0;
}
if (port.c_iflag & IXON)
lpdcb->fInX = 1;