Skip to content

Commit

Permalink
archive/zip: typo h.UncompressedSize > uint32max
Browse files Browse the repository at this point in the history
Should be h.UncompressedSize64 > uint32max

Fixes #33116
  • Loading branch information
philip-firstorder committed Jul 15, 2019
1 parent c0c91c9 commit 5333827
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/archive/zip/writer.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func (w *Writer) Close() error {
}

// append a zip64 extra block to Extra
if h.CompressedSize64 > uint32max || h.UncompressedSize > uint32max || h.offset > uint32max {
if h.CompressedSize64 > uint32max || h.UncompressedSize64 > uint32max || h.offset > uint32max {

zip64ExtraSize := uint16(0)
if h.CompressedSize64 > uint32max {
Expand Down

0 comments on commit 5333827

Please sign in to comment.