1
0
mirror of https://github.com/wjwwood/serial.git synced 2026-01-22 19:54:57 +08:00

Merge 2034e390d851cafce8534e5714afa9d318c16e50 into 69e0372cf0d3796e84ce9a09aff1d74496f68720

This commit is contained in:
Marat Nagayev 2023-12-04 12:23:42 +03:00 committed by GitHub
commit 09bd04a320
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -465,7 +465,8 @@ Serial::SerialImpl::flush ()
if (is_open_ == false) { if (is_open_ == false) {
throw PortNotOpenedException ("Serial::flush"); throw PortNotOpenedException ("Serial::flush");
} }
FlushFileBuffers (fd_); PurgeComm(fd_, PURGE_RXCLEAR);
PurgeComm(fd_, PURGE_TXCLEAR);
} }
void void