mirror of
https://github.com/wjwwood/serial.git
synced 2026-01-22 19:54:57 +08:00
Use PurgeComm for flush
This commit is contained in:
parent
69e0372cf0
commit
2034e390d8
@ -465,7 +465,8 @@ Serial::SerialImpl::flush ()
|
||||
if (is_open_ == false) {
|
||||
throw PortNotOpenedException ("Serial::flush");
|
||||
}
|
||||
FlushFileBuffers (fd_);
|
||||
PurgeComm(fd_, PURGE_RXCLEAR);
|
||||
PurgeComm(fd_, PURGE_TXCLEAR);
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user