Skip to main content

exit_session

Function exit_session 

Source
pub async fn exit_session(control_path: &Path) -> Result<()>
Expand description

Close a ControlMaster session (ssh -O exit); the socket file is unlinked asynchronously, so re-check the path before assuming removal.

ยงErrors

Error::ForwardFailed (non-UTF-8 path), Error::CommandFailed (ssh fails), or Error::TaskFailed (spawn failure).