Merge branch 'master' into oldpr397

This commit is contained in:
Chris Hennick 2024-05-02 11:18:21 -07:00 committed by GitHub
commit 28523f66c0
Signed by: DevComp
GPG key ID: B5690EEEBB952194

View file

@ -29,7 +29,7 @@ use flate2::read::DeflateDecoder;
use deflate64::Deflate64Decoder; use deflate64::Deflate64Decoder;
#[cfg(feature = "bzip2")] #[cfg(feature = "bzip2")]
use bzip2::read::BzDecoder; use bzip2_rs::decoder::DecoderReader;
#[cfg(feature = "zstd")] #[cfg(feature = "zstd")]
use zstd::stream::read::Decoder as ZstdDecoder; use zstd::stream::read::Decoder as ZstdDecoder;
@ -145,7 +145,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<BzDecoder<CryptoReader<'a>>>), Bzip2(Crc32Reader<DecoderReader<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")]
@ -306,7 +306,7 @@ pub(crate) fn make_reader(
} }
#[cfg(feature = "bzip2")] #[cfg(feature = "bzip2")]
CompressionMethod::Bzip2 => { CompressionMethod::Bzip2 => {
let bzip2_reader = BzDecoder::new(reader); let bzip2_reader = DecoderReader::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")]