MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / read_bytes_from_file

Function read_bytes_from_file

rust/src/files.rs:670–676  ·  view source on GitHub ↗
(file_path: &str)

Source from the content-addressed store, hash-verified

668}
669
670pub fn read_bytes_from_file(file_path: &str) -> Result<Vec<u8>, Error> {
671 let file = File::open(file_path)?;
672 let mut reader = BufReader::new(file);
673 let mut buffer = Vec::new();
674 reader.read_to_end(&mut buffer)?;
675 Ok(buffer)
676}
677
678pub fn find_bytes(buffer: &[u8], bytes: &[u8]) -> Option<usize> {
679 buffer

Callers 1

uncompress_sfxFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected