Skip to main content

session_auto_grant_increment

Function session_auto_grant_increment 

Source
pub const fn session_auto_grant_increment(
    already_auto_granted: usize,
    requested: usize,
) -> usize
Expand description

Increment a full-auto run grants itself against the session headroom cap.

Pure so the grant arithmetic stays unit tested without standing up a session. Returns 0 once the headroom is exhausted so the caller can fail closed instead of growing the session limit further.