@@ -7,8 +7,8 @@ use super::super::c;
77use super :: super :: conv:: { msg_control_len, msg_iov_len} ;
88use super :: super :: net:: write_sockaddr:: { encode_sockaddr_v4, encode_sockaddr_v6} ;
99
10- use crate :: io;
11- use crate :: net:: { SocketAddrV4 , SocketAddrV6 } ;
10+ use crate :: io:: { IoSlice , IoSliceMut } ;
11+ use crate :: net:: { RecvAncillaryBuffer , SendAncillaryBuffer , SocketAddrV4 , SocketAddrV6 } ;
1212use crate :: utils:: as_ptr;
1313
1414use core:: convert:: TryInto ;
@@ -17,8 +17,8 @@ use core::mem::{size_of, zeroed, MaybeUninit};
1717/// Create a message header intended to receive a datagram.
1818pub ( crate ) fn with_recv_msghdr < R > (
1919 name : & mut MaybeUninit < c:: sockaddr_storage > ,
20- iov : & mut [ io :: IoSliceMut < ' _ > ] ,
21- control : & mut crate :: net :: RecvAncillaryBuffer < ' _ > ,
20+ iov : & mut [ IoSliceMut < ' _ > ] ,
21+ control : & mut RecvAncillaryBuffer < ' _ > ,
2222 f : impl FnOnce ( & mut c:: msghdr ) -> R ,
2323) -> R {
2424 let namelen = size_of :: < c:: sockaddr_storage > ( ) as c:: socklen_t ;
@@ -45,8 +45,8 @@ pub(crate) fn with_recv_msghdr<R>(
4545
4646/// Create a message header intended to send without an address.
4747pub ( crate ) fn with_noaddr_msghdr < R > (
48- iov : & [ io :: IoSlice < ' _ > ] ,
49- control : & mut crate :: net :: SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
48+ iov : & [ IoSlice < ' _ > ] ,
49+ control : & mut SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
5050 f : impl FnOnce ( c:: msghdr ) -> R ,
5151) -> R {
5252 f ( {
@@ -62,8 +62,8 @@ pub(crate) fn with_noaddr_msghdr<R>(
6262/// Create a message header intended to send with an IPv4 address.
6363pub ( crate ) fn with_v4_msghdr < R > (
6464 addr : & SocketAddrV4 ,
65- iov : & [ io :: IoSlice < ' _ > ] ,
66- control : & mut crate :: net :: SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
65+ iov : & [ IoSlice < ' _ > ] ,
66+ control : & mut SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
6767 f : impl FnOnce ( c:: msghdr ) -> R ,
6868) -> R {
6969 let encoded = unsafe { encode_sockaddr_v4 ( addr) } ;
@@ -83,8 +83,8 @@ pub(crate) fn with_v4_msghdr<R>(
8383/// Create a message header intended to send with an IPv6 address.
8484pub ( crate ) fn with_v6_msghdr < R > (
8585 addr : & SocketAddrV6 ,
86- iov : & [ io :: IoSlice < ' _ > ] ,
87- control : & mut crate :: net :: SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
86+ iov : & [ IoSlice < ' _ > ] ,
87+ control : & mut SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
8888 f : impl FnOnce ( c:: msghdr ) -> R ,
8989) -> R {
9090 let encoded = unsafe { encode_sockaddr_v6 ( addr) } ;
@@ -105,8 +105,8 @@ pub(crate) fn with_v6_msghdr<R>(
105105#[ cfg( all( unix, not( target_os = "redox" ) ) ) ]
106106pub ( crate ) fn with_unix_msghdr < R > (
107107 addr : & crate :: net:: SocketAddrUnix ,
108- iov : & [ io :: IoSlice < ' _ > ] ,
109- control : & mut crate :: net :: SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
108+ iov : & [ IoSlice < ' _ > ] ,
109+ control : & mut SendAncillaryBuffer < ' _ , ' _ , ' _ > ,
110110 f : impl FnOnce ( c:: msghdr ) -> R ,
111111) -> R {
112112 f ( {
0 commit comments