Remove AsRaw{Fd, Socket} impls

An SslStream can't really act as a raw socket since you'd skip the whole
TLS layer
This commit is contained in:
Steven Fackler 2016-05-02 21:29:25 -07:00
parent f1846bce78
commit 356d4a0420
1 changed files with 0 additions and 18 deletions

View File

@ -17,10 +17,6 @@ use libc::{c_uchar, c_uint};
#[cfg(any(feature = "npn", feature = "alpn"))] #[cfg(any(feature = "npn", feature = "alpn"))]
use std::slice; use std::slice;
use std::marker::PhantomData; use std::marker::PhantomData;
#[cfg(unix)]
use std::os::unix::io::{AsRawFd, RawFd};
#[cfg(windows)]
use std::os::windows::io::{AsRawSocket, RawSocket};
use ffi; use ffi;
use ffi_extras; use ffi_extras;
@ -1052,20 +1048,6 @@ impl<S> fmt::Debug for SslStream<S> where S: fmt::Debug
} }
} }
#[cfg(unix)]
impl<S: AsRawFd> AsRawFd for SslStream<S> {
fn as_raw_fd(&self) -> RawFd {
self.get_ref().as_raw_fd()
}
}
#[cfg(windows)]
impl<S: AsRawSocket> AsRawSocket for SslStream<S> {
fn as_raw_socket(&self) -> RawSocket {
self.get_ref().as_raw_socket()
}
}
impl<S: Read + Write> SslStream<S> { impl<S: Read + Write> SslStream<S> {
fn new_base(ssl: Ssl, stream: S) -> Self { fn new_base(ssl: Ssl, stream: S) -> Self {
unsafe { unsafe {