net: implement AsRawSocket on Windows (#2911)

This commit is contained in:
Taiki Endo 2020-10-06 02:22:19 +09:00 committed by GitHub
parent 242ea01189
commit 561a71ad63
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 24 additions and 30 deletions

View File

@ -431,14 +431,12 @@ mod sys {
#[cfg(windows)] #[cfg(windows)]
mod sys { mod sys {
// TODO: let's land these upstream with mio and then we can add them here. use super::TcpListener;
// use std::os::windows::prelude::*;
// use std::os::windows::prelude::*;
// use super::{TcpListener; impl AsRawSocket for TcpListener {
// fn as_raw_socket(&self) -> RawSocket {
// impl AsRawHandle for TcpListener { self.io.get_ref().as_raw_socket()
// fn as_raw_handle(&self) -> RawHandle { }
// self.listener.io().as_raw_handle() }
// }
// }
} }

View File

@ -596,14 +596,12 @@ mod sys {
#[cfg(windows)] #[cfg(windows)]
mod sys { mod sys {
// TODO: let's land these upstream with mio and then we can add them here. use super::TcpStream;
// use std::os::windows::prelude::*;
// use std::os::windows::prelude::*;
// use super::TcpStream; impl AsRawSocket for TcpStream {
// fn as_raw_socket(&self) -> RawSocket {
// impl AsRawHandle for TcpStream { self.io.get_ref().as_raw_socket()
// fn as_raw_handle(&self) -> RawHandle { }
// self.io.get_ref().as_raw_handle() }
// }
// }
} }

View File

@ -356,14 +356,12 @@ mod sys {
#[cfg(windows)] #[cfg(windows)]
mod sys { mod sys {
// TODO: let's land these upstream with mio and then we can add them here. use super::UdpSocket;
// use std::os::windows::prelude::*;
// use std::os::windows::prelude::*;
// use super::UdpSocket; impl AsRawSocket for UdpSocket {
// fn as_raw_socket(&self) -> RawSocket {
// impl AsRawHandle for UdpSocket { self.io.get_ref().as_raw_socket()
// fn as_raw_handle(&self) -> RawHandle { }
// self.io.get_ref().as_raw_handle() }
// }
// }
} }