Closed vi closed 4 years ago
How do I do full-duplex communication using Device without using AsRawFd, just with std::io::Read and std::io::Write?
Device
AsRawFd
std::io::Read
std::io::Write
Maybe Device should have try_clone(), so both copies can be sent to separate threads?
try_clone()
@vi Check this pub fn split(self) -> (Reader, Writer) (https://docs.rs/tun/0.4.4/tun/platform/struct.Device.html#method.split)
pub fn split(self) -> (Reader, Writer)
How do I do full-duplex communication using
Device
without usingAsRawFd
, just withstd::io::Read
andstd::io::Write
?Maybe
Device
should havetry_clone()
, so both copies can be sent to separate threads?