From f4ec9a6360c5e2d3066dc5b278f116c8febe701c Mon Sep 17 00:00:00 2001 From: Carl Lerche Date: Tue, 30 Jan 2018 12:59:23 -0800 Subject: [PATCH] Remove only_v6 from TCP types (#90) --- src/net/tcp.rs | 42 ------------------------------------------ 1 file changed, 42 deletions(-) diff --git a/src/net/tcp.rs b/src/net/tcp.rs index 0861b7a64..352e9db90 100644 --- a/src/net/tcp.rs +++ b/src/net/tcp.rs @@ -173,27 +173,6 @@ impl TcpListener { pub fn set_ttl(&self, ttl: u32) -> io::Result<()> { self.io.get_ref().set_ttl(ttl) } - - /// Gets the value of the `IPV6_V6ONLY` option for this socket. - /// - /// For more information about this option, see [`set_only_v6`]. - /// - /// [`set_only_v6`]: #method.set_only_v6 - pub fn only_v6(&self) -> io::Result { - self.io.get_ref().only_v6() - } - - /// Sets the value for the `IPV6_V6ONLY` option on this socket. - /// - /// If this is set to `true` then the socket is restricted to sending and - /// receiving IPv6 packets only. In this case two IPv4 and IPv6 applications - /// can bind the same port at the same time. - /// - /// If this is set to `false` then the socket can be used to send and - /// receive packets from an IPv4-mapped IPv6 address. - pub fn set_only_v6(&self, only_v6: bool) -> io::Result<()> { - self.io.get_ref().set_only_v6(only_v6) - } } impl fmt::Debug for TcpListener { @@ -470,27 +449,6 @@ impl TcpStream { self.io.get_ref().set_ttl(ttl) } - /// Gets the value of the `IPV6_V6ONLY` option for this socket. - /// - /// For more information about this option, see [`set_only_v6`]. - /// - /// [`set_only_v6`]: #tymethod.set_only_v6 - pub fn only_v6(&self) -> io::Result { - self.io.get_ref().only_v6() - } - - /// Sets the value for the `IPV6_V6ONLY` option on this socket. - /// - /// If this is set to `true` then the socket is restricted to sending and - /// receiving IPv6 packets only. In this case two IPv4 and IPv6 applications - /// can bind the same port at the same time. - /// - /// If this is set to `false` then the socket can be used to send and - /// receive packets from an IPv4-mapped IPv6 address. - pub fn set_only_v6(&self, only_v6: bool) -> io::Result<()> { - self.io.get_ref().set_only_v6(only_v6) - } - /// Reads the linger duration for this socket by getting the `SO_LINGER` /// option. ///