kratart: async image extraction

This commit is contained in:
alex committed 2024-03-08 14:44:45 +00:00
1 parent b0bd931f0e
commit 817509bcef
12 files changed
+674 -544

No files matched your search

-5
View File
@@ -62,11 +62,6 @@ impl ElfImageLoader {
ElfImageLoader { data }
}
pub fn load_file(path: &str) -> Result<ElfImageLoader> {
let data = std::fs::read(path)?;
Ok(ElfImageLoader::new(data))
}
pub fn load_gz(data: &[u8]) -> Result<ElfImageLoader> {
let buff = BufReader::new(data);
let image = ElfImageLoader::read_one_stream(&mut GzDecoder::new(buff))?;