File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -342,14 +342,15 @@ macro_rules! impl_nio_read_iovec {
342342 std:: ffi:: c_uint:: try_from( arg. len( ) ) . unwrap_or_else( |_| {
343343 panic!( "{} iovcnt overflow" , $crate:: common:: constants:: SyscallName :: $syscall)
344344 } ) ,
345+ $recvd,
345346 $( $arg, ) *
346347 ) ;
347348 if r != -1 {
348349 $crate:: syscall:: reset_errno( ) ;
349350 received += usize :: try_from( r) . expect( "overflow" ) ;
350351 if received >= length {
351352 r = 0 ;
352- unsafe { $received . write( received. try_into( ) . expect( "overflow" ) ) } ;
353+ unsafe { $recvd . write( received. try_into( ) . expect( "overflow" ) ) } ;
353354 break ;
354355 }
355356 offset = received. saturating_sub( length) ;
@@ -367,7 +368,7 @@ macro_rules! impl_nio_read_iovec {
367368 Some ( wait_time)
368369 ) . is_err( ) {
369370 r = 0 ;
370- unsafe { $received . write( received. try_into( ) . expect( "overflow" ) ) } ;
371+ unsafe { $recvd . write( received. try_into( ) . expect( "overflow" ) ) } ;
371372 std:: mem:: forget( vec) ;
372373 if blocking {
373374 $crate:: syscall:: set_blocking( $fd) ;
@@ -556,6 +557,7 @@ macro_rules! impl_nio_write_iovec {
556557 std:: ffi:: c_uint:: try_from( arg. len( ) ) . unwrap_or_else( |_| {
557558 panic!( "{} iovcnt overflow" , $crate:: common:: constants:: SyscallName :: $syscall)
558559 } ) ,
560+ $sent,
559561 $( $arg, ) *
560562 ) ;
561563 if r != -1 {
You can’t perform that action at this time.
0 commit comments