Skip to main content

socket_action_deadline

Function socket_action_deadline 

Source
pub(crate) fn socket_action_deadline<'tcx>(
    ecx: &MiriInterpCx<'tcx>,
    is_non_block: bool,
    action_timeout: Option<Duration>,
) -> Option<Deadline>
Expand description

Get the deadline for an action (e.g. reading or writing). When is_non_block is true, the returned deadline is “now”, i.e., we wake up immediately if the action cannot be completed. If action_timeout is Some(duration), the returned deadline is in the future, at now + duration. Otherwise, no deadline (None) is returned, indicating that the action can block indefinitely.