use std::ffi::OsStr;
use std::os::unix::ffi::OsStrExt;
pub fn starts_with(src: &OsStr, contains: &OsStr) -> bool {
let src_bytes = src.as_bytes();
for (index, byte) in contains.as_bytes().iter().enumerate() {
if src_bytes[index] != *byte {
return false;
}
}
true
}