pub fn read_file(path: &str) -> Result<Vec<u8>, KernelError>Expand description
Read the entire contents of a file into a Vec
This is a convenience function that opens a file, reads its entire contents into memory, and returns the data as a byte vector.
§Arguments
path- The filesystem path to the file
§Returns
Ok(Vec<u8>)- The file contents on successErr(&'static str)- An error message on failure