cap_primitives/fs/
errors.rs

1use std::io;
2
3#[cfg(not(windows))]
4pub(crate) use crate::rustix::fs::errors::*;
5#[cfg(windows)]
6pub(crate) use crate::windows::fs::errors::*;
7
8#[cold]
9pub(crate) fn escape_attempt() -> io::Error {
10    io::Error::new(
11        io::ErrorKind::PermissionDenied,
12        "a path led outside of the filesystem",
13    )
14}