Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(zip): dont fail test on 0 sizes and descriptor #736

Merged
merged 1 commit into from
Mar 23, 2022

Conversation

piksel
Copy link
Member

@piksel piksel commented Mar 23, 2022

Fixing what seems like a merge artifact (7 years ago!) that fails the LocalHeaderTests when an archive is using Zip64 and Descriptors, and the size in the local Zip64 extra data is set to 0 (which is per spec).

This also replaces the bitwise flag checks with a helper method to increase legibility (not mixing boolean and bitwise logic).

Fixes #735

@codecov
Copy link

codecov bot commented Mar 23, 2022

Codecov Report

Merging #736 (c761aae) into master (71fe846) will increase coverage by 0.00%.
The diff coverage is 88.88%.

@@           Coverage Diff           @@
##           master     #736   +/-   ##
=======================================
  Coverage   73.82%   73.83%           
=======================================
  Files          68       69    +1     
  Lines        8353     8355    +2     
=======================================
+ Hits         6167     6169    +2     
  Misses       2186     2186           
Impacted Files Coverage Δ
src/ICSharpCode.SharpZipLib/Zip/ZipConstants.cs 50.00% <50.00%> (ø)
src/ICSharpCode.SharpZipLib/Zip/ZipFile.cs 77.28% <93.75%> (ø)
src/ICSharpCode.SharpZipLib/Zip/ZipStrings.cs 48.83% <0.00%> (+2.32%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 71fe846...c761aae. Read the comment docs.

@piksel piksel force-pushed the fix/localheadertestsize64 branch from 44d246c to c761aae Compare March 23, 2022 12:35
@piksel piksel merged commit cc8dd78 into master Mar 23, 2022
@piksel piksel deleted the fix/localheadertestsize64 branch March 23, 2022 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problem reading archives containg Zip64 files
1 participant