File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
library/std/src/os/unix/net Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -664,11 +664,11 @@ impl io::Write for UnixStream {
664
664
#[ stable( feature = "unix_socket" , since = "1.10.0" ) ]
665
665
impl < ' a > io:: Write for & ' a UnixStream {
666
666
fn write ( & mut self , buf : & [ u8 ] ) -> io:: Result < usize > {
667
- let len = cmp:: min ( buf. len ( ) , <wrlen_t >:: MAX as usize ) as wrlen_t ;
668
- let ret = cvt ( unsafe {
669
- libc:: send ( self . 0 . as_raw ( ) , buf. as_ptr ( ) as * const c_void , len, MSG_NOSIGNAL )
670
- } ) ?;
671
- Ok ( ret as usize )
667
+ let len = cmp:: min ( buf. len ( ) , <wrlen_t >:: MAX as usize ) as wrlen_t ;
668
+ let ret = cvt ( unsafe {
669
+ libc:: send ( self . 0 . as_raw ( ) , buf. as_ptr ( ) as * const c_void , len, MSG_NOSIGNAL )
670
+ } ) ?;
671
+ Ok ( ret as usize )
672
672
}
673
673
674
674
fn write_vectored ( & mut self , bufs : & [ IoSlice < ' _ > ] ) -> io:: Result < usize > {
You can’t perform that action at this time.
0 commit comments