(decoded: &[u8])
| 228 | } |
| 229 | |
| 230 | fn split_path_segments(decoded: &[u8]) -> Vec<&[u8]> { |
| 231 | // decoded is guaranteed to start with `/`. Skip the leading `/` and |
| 232 | // split on subsequent `/` bytes. The sentinel byte for encoded slashes |
| 233 | // never matches, so it stays inside its segment. |
| 234 | decoded[1..].split(|&b| b == b'/').collect() |
| 235 | } |
| 236 | |
| 237 | fn resolve_dot_segments(segments: Vec<&[u8]>) -> Result<Vec<Vec<u8>>, CanonicalizeError> { |
| 238 | let mut stack: Vec<Vec<u8>> = Vec::with_capacity(segments.len()); |
no outgoing calls
no test coverage detected