Upgrade unrar to master branch to fix Utf8Error
This commit is contained in:
parent
e69165fe5a
commit
81f12da99c
13
Cargo.lock
generated
13
Cargo.lock
generated
@ -2299,8 +2299,7 @@ checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e"
|
||||
[[package]]
|
||||
name = "unrar"
|
||||
version = "0.4.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "433cea4f0b7bec88d47becb380887b8786a3cfb1c82e1ef9d32a682ba6801814"
|
||||
source = "git+https://github.com/muja/unrar.rs.git#d4f20fc09c7a6f6e7e50ad02f1e86e9de44b78ce"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"enum_primitive",
|
||||
@ -2308,13 +2307,13 @@ dependencies = [
|
||||
"num",
|
||||
"regex",
|
||||
"unrar_sys",
|
||||
"widestring",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "unrar_sys"
|
||||
version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0009399408dc0bcc5c8910672544fceceeba18b91f741ff943916e917d982c60"
|
||||
source = "git+https://github.com/muja/unrar.rs.git#d4f20fc09c7a6f6e7e50ad02f1e86e9de44b78ce"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"libc",
|
||||
@ -2461,6 +2460,12 @@ dependencies = [
|
||||
"web-sys",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "widestring"
|
||||
version = "0.4.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c168940144dd21fd8046987c16a46a33d5fc84eec29ef9dcddc2ac9e31526b7c"
|
||||
|
||||
[[package]]
|
||||
name = "winapi"
|
||||
version = "0.3.9"
|
||||
|
@ -29,6 +29,7 @@ tokio-util = { version = "0.6", features = ["compat"] }
|
||||
tracing = "0.1"
|
||||
tracing-appender = "0.1"
|
||||
tracing-subscriber = "0.2"
|
||||
unrar = "0.4"
|
||||
# Need this unicode fix: https://github.com/muja/unrar.rs/commit/3af9a6015dc89c1329a2fe5d6f4a7f69ded8ba1d
|
||||
unrar = { git = "https://github.com/muja/unrar.rs.git" }
|
||||
# Need `ZipWriter::append_new` from https://github.com/zip-rs/zip/commit/ce272616ac69b798bb7b0925147a8a710dc2bb65
|
||||
zip = { git = "https://github.com/zip-rs/zip.git" }
|
@ -391,7 +391,7 @@ pub async fn main() -> Result<()> {
|
||||
|
||||
let mut plugin_file_paths = Vec::new();
|
||||
let list =
|
||||
Archive::new(temp_file_path.to_string_lossy().to_string()).list();
|
||||
Archive::new(&temp_file_path.to_string_lossy().to_string())?.list();
|
||||
if let Ok(list) = list {
|
||||
for entry in list {
|
||||
if let Ok(entry) = entry {
|
||||
@ -421,7 +421,7 @@ pub async fn main() -> Result<()> {
|
||||
if plugin_file_paths.len() > 0 {
|
||||
info!("uncompressing downloaded archive");
|
||||
let extract =
|
||||
Archive::new(temp_file_path.to_string_lossy().to_string())
|
||||
Archive::new(&temp_file_path.to_string_lossy().to_string())?
|
||||
.extract_to(temp_dir.path().to_string_lossy().to_string());
|
||||
extract
|
||||
.expect("failed to extract")
|
||||
@ -441,7 +441,7 @@ pub async fn main() -> Result<()> {
|
||||
&mut plugins_archive,
|
||||
&db_file,
|
||||
&db_mod,
|
||||
file_path,
|
||||
&file_path.to_string_lossy(),
|
||||
)
|
||||
.await?;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user