mirror of
https://gitea.tendokyu.moe/beerpsi/fsdecrypt.git
synced 2026-09-29 10:17:54 +03:00
port buffering to exfat extraction
This commit is contained in:
Generated
+1
-1
@@ -507,7 +507,7 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
|
||||
|
||||
[[package]]
|
||||
name = "fsdecrypt"
|
||||
version = "0.1.3"
|
||||
version = "0.1.4"
|
||||
dependencies = [
|
||||
"aes",
|
||||
"anyhow",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "fsdecrypt"
|
||||
version = "0.1.3"
|
||||
version = "0.1.4"
|
||||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
|
||||
+4
-2
@@ -84,8 +84,6 @@ fn extract_exfat_elements(elements: &mut [FsElement<File>], output_dir: &Path) -
|
||||
let dest_path = output_dir.join(file.name());
|
||||
let mut dest = File::create(dest_path)?;
|
||||
|
||||
std::io::copy(file, &mut dest)?;
|
||||
|
||||
dest.set_times(
|
||||
FileTimes::new()
|
||||
.set_accessed(exfat_timestamp_to_system_time(
|
||||
@@ -95,6 +93,10 @@ fn extract_exfat_elements(elements: &mut [FsElement<File>], output_dir: &Path) -
|
||||
file.timestamps().modified(),
|
||||
)?),
|
||||
)?;
|
||||
|
||||
let mut writer = BufWriter::with_capacity(256 * 1024, &mut dest);
|
||||
|
||||
std::io::copy(file, &mut writer)?;
|
||||
}
|
||||
FsElement::D(directory) => {
|
||||
let dest_path = output_dir.join(directory.name());
|
||||
|
||||
Reference in New Issue
Block a user