136 Commits

Author SHA1 Message Date
Timofey Solomko d9bb44001d Merge branch 'hotfix-4.9.1' into develop 2026-06-13 16:21:33 +08:00
Timofey Solomko e75d4bb167 [ZIP] Decode CP437 manually on non-Darwin platforms with Swift earlier than 6.2
Fixes #65.
2026-06-13 16:11:11 +08:00
Timofey Solomko 1b2c9ccc0a [ZIP] Mark extra field-related types as Sendable 2026-05-26 11:56:54 +08:00
Timofey Solomko 0359b943ea [ZIP] Mark customExtraFields as nonisolated(unsafe)
This is a temporary measure to "fix" compilation errors in Swift 6 language mode. Ultimately, this is a global variable which is not really concurrency-safe, so the entire custom extra field management system should be rethought.
2026-05-26 11:19:28 +08:00
Timofey Solomko 273b6ed9e9 Remove redundant imports 2026-02-18 12:21:57 +08:00
Timofey Solomko 1566b49ce3 [7-Zip][ZIP] Remove support for CocoaPods optional dependencies 2026-02-03 01:15:33 +08:00
Timofey Solomko ea9aaccfb9 Update copyright year to 2026 2026-01-31 15:30:24 +08:00
Timofey Solomko ed66991cbd Update copyright year to 2024 2024-01-11 16:57:04 +03:00
Timofey Solomko 43132fc39d Update copyright year to 2023 2023-02-07 15:31:45 +02:00
Timofey Solomko 79295db930 Update copyright year to 2022 2022-01-08 15:02:59 +03:00
Timofey Solomko 6971656b63 Two minor changes: make Checksums a caseless enum, fix a grammar mistake in a code comment 2021-11-04 12:10:39 +03:00
Timofey Solomko a3332364a7 [Tests] Add many tests that check that checksum errors are thrown correctly 2021-10-29 19:26:33 +03:00
Timofey Solomko 20e8db701f [Tests] Add a test for correct usage of CP437 in ZIP 2021-10-28 19:54:25 +03:00
Timofey Solomko 7c6c98b3a3 [ZIP] Remove unused import 2021-09-20 12:00:12 +03:00
Timofey Solomko 86a9caf337 [ZIP] Unify the code for finding CP437 enconding 2021-09-19 18:28:25 +03:00
Timofey Solomko ff269e3ffe [ZIP] Rename ByteReader+Zip to LittleEndianByteReader+Zip 2021-07-27 16:19:06 +03:00
Eric Thorpe 69eb11437a [ZIP] Fix CP437 support on Windows 2021-05-13 21:54:16 +03:00
Timofey Solomko 1f7a5352a7 [BZip2] Explain zero RLE in the comments 2021-01-18 16:07:44 +02:00
Timofey Solomko e83f23effa Update copyright year to 2021 2021-01-11 11:20:57 +02:00
Timofey Solomko deab72a831 Merge branch 'hotfix-4.5.7' into develop 2020-10-16 15:57:08 +03:00
Timofey Solomko 9360a8a9b8 [ZIP] Fix a crash when opening a very small file
Such files (smaller than 22 bytes) definitely don't have a EndOfCD and in this case ZipError.notFoundCentralDirectoryEnd should be properly thrown.
2020-10-15 23:35:22 +03:00
Timofey Solomko fa552e9b61 [ZIP] Fix a crash when opening a file without EndOfCD
Now ZipError.notFoundCentralDirectoryEnd is correctly thrown as was originally intended.
2020-10-14 23:51:27 +03:00
Timofey Solomko 2909f4e0c7 Merge branch 'hotfix-4.5.6' into develop 2020-09-24 23:13:26 +03:00
Timofey Solomko 2c46351a44 Fix building issue with swift 5.3 on linux 2020-09-24 13:06:54 +03:00
Timofey Solomko 761f0a0a3f Merge branch 'hotfix-4.5.5' into develop 2020-04-27 16:16:50 +03:00
Timofey Solomko 1ed0cdfdfa [ZIP] Fix a crash when encountering non well-formed Extended Timestamp
ZIP files produced by Finder on certain versions of macOS sometimes contain incorrect Extended Timestamp extra field in their Central Directory. When trying to open such files, SWCompression was crashing. This change makes SWCompression ignore "incorrectness" in Extended Timestamp.
2020-04-26 23:11:14 +03:00
Timofey Solomko 247def898b [BZip2][ZIP] Small code optimizations
A variable in BZip2 code changed to let-constant and two fields of ZIP's "end of central directory" struct are no longer properties since they aren't used anywhere.
2020-04-16 22:41:41 +03:00
Timofey Solomko a844b34436 Update copyright year to 2020 2020-03-20 09:43:42 +03:00
Timofey Solomko f6949a8f66 Replace the usage of the deprecated Data(bytes:) initializer 2020-03-20 09:40:48 +03:00
Timofey Solomko 31ec1f1553 Update copyright year to 2020 2020-01-01 19:06:33 +03:00
Timofey Solomko 75b21ae107 Replace usage of ByteReader with LittleEndianByteReader 2019-05-01 19:34:30 +03:00
Timofey Solomko db82490ed8 Replace the usage of the deprecated Data(bytes:) initializer 2019-05-01 19:30:48 +03:00
Timofey Solomko c93a783d21 [docs] Fix grammar issues with regards to a/the/null articles, while/during, and extra commas 2019-03-13 12:27:08 +03:00
Timofey Solomko ce47019097 Update copyright year to 2019 2019-01-02 23:15:43 +03:00
Timofey Solomko 12d8836529 [ZIP] Use the new ZipEntryInfoHelper and remove its properties from ZipEntryInfo 2019-01-01 13:28:50 +03:00
Timofey Solomko 2273c1e12c [ZIP] Add a new struct, ZipEntryInfoHelper, which is supposed to store additional information to _help_ ZipContainer get entry's data 2019-01-01 13:27:46 +03:00
Timofey Solomko 59d31fdb5a Swiftlinted for 4.5.0 2018-09-06 20:11:18 +03:00
Timofey Solomko f5d8d9e81e [LZMA] Add LZMAProperties initializer which reads lzma encoded properties from bytereader 2018-08-28 11:36:34 +03:00
Timofey Solomko 9a79aa8e51 [LZMA][ZIP] Add public function with data as first argument and internal function with byteReader instead which also accept LZMA properties and uncompressed size as
arguments; replace old internal decompress function used by ZIP with a new, more general one
2018-08-28 11:35:56 +03:00
Timofey Solomko c9115f367b [ZIP] Replace stored local header and cd entry in ZipEntryInfo with separate actually required properties 2018-08-13 11:38:42 +03:00
Timofey Solomko ffd47c3528 [ZIP] Set ZipEntryInfo.crc properly depending on the presence of data descriptor 2018-08-13 11:37:44 +03:00
Timofey Solomko 65fdc944bf [ZIP] Remove useless code comments 2018-08-12 20:59:57 +03:00
Timofey Solomko f0308c1ed8 [ZIP] Add public crc32 property to EntryInfo 2018-08-12 20:59:08 +03:00
Timofey Solomko 1264a194c2 [docs] Refer to "standard" extra fields as "built-in" 2018-08-12 20:52:44 +03:00
Timofey Solomko 05054ba26d [ZIP] Rename ByteReader+ZipString file to ByteReader+Zip
This is also consistent with tar extensions to ByteReader.
2018-08-12 19:31:47 +03:00
Timofey Solomko 113dcea56c [ZIP] Rename ByteReader.getZipStringField to zipString
This is consistent with tar extensions to ByteReader
2018-08-12 19:30:34 +03:00
Timofey Solomko 3ed501cdfd [ZIP] Replace ZipString class with fileprivate extensions to String and Data 2018-08-12 19:28:45 +03:00
Timofey Solomko e467370de7 [LZMA] Remove second label from internal LZMA.decompress function and simplify uncompSize processing 2018-05-20 12:26:25 +03:00
Timofey Solomko 41ca39d1fa Remove certain TODOs 2018-04-10 23:26:35 +03:00
Timofey Solomko a0ef7a3cfe Swiftlinted 2018-04-10 23:22:31 +03:00