ntdll: Fix DTR and CTS controls in serial code.

This commit is contained in:
Reinhard Karcher 2007-01-01 17:41:52 +01:00 committed by Alexandre Julliard
parent 9196a37201
commit 64c1c017c4
1 changed files with 3 additions and 3 deletions

View File

@ -595,13 +595,13 @@ static NTSTATUS set_handflow(int fd, const SERIAL_HANDFLOW* shf)
if (shf->ControlHandShake & SERIAL_DTR_HANDSHAKE)
{
WARN("DSR/DTR flow control not supported\n");
} else if (shf->ControlHandShake & SERIAL_DTR_CONTROL)
} else if (!(shf->ControlHandShake & SERIAL_DTR_CONTROL))
whack_modem(fd, ~TIOCM_DTR, 0);
else
else
whack_modem(fd, 0, TIOCM_DTR);
#endif
#ifdef TIOCM_RTS
if (!(shf->ControlHandShake & SERIAL_DSR_HANDSHAKE))
if (!(shf->ControlHandShake & SERIAL_CTS_HANDSHAKE))
{
if ((shf->FlowReplace & (SERIAL_RTS_CONTROL|SERIAL_RTS_HANDSHAKE)) == 0)
whack_modem(fd, ~TIOCM_RTS, 0);