You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// let mut buffer1 = vec![0u8; message1.len() + message2.len()];
499
-
/// let mut time1: CmsgSpace<TimeVal> = CmsgSpace::new();
500
-
/// let received1 = recvmsg(in_socket, &[IoVec::from_mut_slice(&mut buffer1)], Some(&mut time1), MsgFlags::empty()).unwrap();
501
-
/// let mut time1 = if let Some(ControlMessage::ScmTimestamp(&time1)) = received1.cmsgs().next() { time1 } else { panic!("Unexpected or no control message") };
502
-
///
503
-
/// // Receive the second
504
-
/// let mut buffer2 = vec![0u8; message1.len() + message2.len()];
505
-
/// let mut time2: CmsgSpace<TimeVal> = CmsgSpace::new();
506
-
/// let received2 = recvmsg(in_socket, &[IoVec::from_mut_slice(&mut buffer2)], Some(&mut time2), MsgFlags::empty()).unwrap();
507
-
/// let mut time2 = if let Some(ControlMessage::ScmTimestamp(&time2)) = received2.cmsgs().next() { time2 } else { panic!("Unexpected or no control message") };
508
-
///
509
-
/// // Swap if needed; UDP is unordered
510
-
/// match (received1.bytes, received2.bytes, message1.len(), message2.len()) {
0 commit comments