jcurl / RJCP.DLL.SerialPortStream

SerialPortStream is an independent implementation of System.IO.Ports.SerialPort and SerialStream for better reliability and maintainability. Default branch is 2.x and now has support for Mono with help of a C library.
Microsoft Public License
614 stars 196 forks source link

tcdrain or tcflush for flushing #99

Open zii-dmg opened 4 years ago

zii-dmg commented 4 years ago

In this https://github.com/dotnet/corefx/commit/45dba6ea7a49a9945a5ad497cfc3de2ec1246683#diff-221055955142c33d285c9271ba435005 .NET Core team replaced tcflush with tcdrain. Maybe SerialPortStream should use tcdrain too, because tcflush discards bytes, but Flush() API should send them.

https://linux.die.net/man/3/tcdrain: