Merge branch 'master' into oldpr437a
This commit is contained in:
commit
c3fe6f0954
2 changed files with 5 additions and 7 deletions
|
@ -24,7 +24,7 @@ time = { version = "0.3.36", default-features = false }
|
||||||
[dependencies]
|
[dependencies]
|
||||||
aes = { version = "0.8.4", optional = true }
|
aes = { version = "0.8.4", optional = true }
|
||||||
byteorder = "1.5.0"
|
byteorder = "1.5.0"
|
||||||
bzip2-rs = { version = "0.1.2", optional = true }
|
bzip2 = { version = "0.4.4", optional = true }
|
||||||
chrono = { version = "0.4.38", optional = true }
|
chrono = { version = "0.4.38", optional = true }
|
||||||
constant_time_eq = { version = "0.3.0", optional = true }
|
constant_time_eq = { version = "0.3.0", optional = true }
|
||||||
crc32fast = "1.4.0"
|
crc32fast = "1.4.0"
|
||||||
|
@ -52,9 +52,7 @@ getrandom = { version = "0.2.14", features = ["js"] }
|
||||||
walkdir = "2.5.0"
|
walkdir = "2.5.0"
|
||||||
time = { workspace = true, features = ["formatting", "macros"] }
|
time = { workspace = true, features = ["formatting", "macros"] }
|
||||||
anyhow = "1"
|
anyhow = "1"
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
bzip2 = ["bzip2-rs"]
|
|
||||||
aes-crypto = ["aes", "constant_time_eq", "hmac", "pbkdf2", "sha1"]
|
aes-crypto = ["aes", "constant_time_eq", "hmac", "pbkdf2", "sha1"]
|
||||||
chrono = ["chrono/default"]
|
chrono = ["chrono/default"]
|
||||||
_deflate-any = []
|
_deflate-any = []
|
||||||
|
@ -70,7 +68,7 @@ lzma = ["lzma-rs/stream"]
|
||||||
unreserved = []
|
unreserved = []
|
||||||
default = [
|
default = [
|
||||||
"aes-crypto",
|
"aes-crypto",
|
||||||
"bzip2-rs",
|
"bzip2",
|
||||||
"deflate",
|
"deflate",
|
||||||
"deflate64",
|
"deflate64",
|
||||||
"deflate-zlib-ng",
|
"deflate-zlib-ng",
|
||||||
|
|
|
@ -30,7 +30,7 @@ use flate2::read::DeflateDecoder;
|
||||||
use deflate64::Deflate64Decoder;
|
use deflate64::Deflate64Decoder;
|
||||||
|
|
||||||
#[cfg(feature = "bzip2")]
|
#[cfg(feature = "bzip2")]
|
||||||
use bzip2_rs::decoder::DecoderReader;
|
use bzip2::read::BzDecoder;
|
||||||
|
|
||||||
#[cfg(feature = "zstd")]
|
#[cfg(feature = "zstd")]
|
||||||
use zstd::stream::read::Decoder as ZstdDecoder;
|
use zstd::stream::read::Decoder as ZstdDecoder;
|
||||||
|
@ -146,7 +146,7 @@ pub(crate) enum ZipFileReader<'a> {
|
||||||
#[cfg(feature = "deflate64")]
|
#[cfg(feature = "deflate64")]
|
||||||
Deflate64(Crc32Reader<Deflate64Decoder<io::BufReader<CryptoReader<'a>>>>),
|
Deflate64(Crc32Reader<Deflate64Decoder<io::BufReader<CryptoReader<'a>>>>),
|
||||||
#[cfg(feature = "bzip2")]
|
#[cfg(feature = "bzip2")]
|
||||||
Bzip2(Crc32Reader<DecoderReader<CryptoReader<'a>>>),
|
Bzip2(Crc32Reader<BzDecoder<CryptoReader<'a>>>),
|
||||||
#[cfg(feature = "zstd")]
|
#[cfg(feature = "zstd")]
|
||||||
Zstd(Crc32Reader<ZstdDecoder<'a, io::BufReader<CryptoReader<'a>>>>),
|
Zstd(Crc32Reader<ZstdDecoder<'a, io::BufReader<CryptoReader<'a>>>>),
|
||||||
#[cfg(feature = "lzma")]
|
#[cfg(feature = "lzma")]
|
||||||
|
@ -307,7 +307,7 @@ pub(crate) fn make_reader(
|
||||||
}
|
}
|
||||||
#[cfg(feature = "bzip2")]
|
#[cfg(feature = "bzip2")]
|
||||||
CompressionMethod::Bzip2 => {
|
CompressionMethod::Bzip2 => {
|
||||||
let bzip2_reader = DecoderReader::new(reader);
|
let bzip2_reader = BzDecoder::new(reader);
|
||||||
ZipFileReader::Bzip2(Crc32Reader::new(bzip2_reader, crc32, ae2_encrypted))
|
ZipFileReader::Bzip2(Crc32Reader::new(bzip2_reader, crc32, ae2_encrypted))
|
||||||
}
|
}
|
||||||
#[cfg(feature = "zstd")]
|
#[cfg(feature = "zstd")]
|
||||||
|
|
Loading…
Add table
Reference in a new issue