Skip to content

Commit

Permalink
Merge pull request #210 from kenkendk/fix_invalid_headers
Browse files Browse the repository at this point in the history
Fix invalid headers
  • Loading branch information
adamhathcock authored Mar 9, 2017
2 parents 9f90a1d + 81ab5c1 commit d0b4af6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/SharpCompress/Common/Zip/Headers/DirectoryEntryHeader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ internal override void Write(BinaryWriter writer)
writer.Write(LastModifiedTime);
writer.Write(LastModifiedDate);
writer.Write(Crc);
writer.Write(CompressedSize);
writer.Write(UncompressedSize);
writer.Write((uint)CompressedSize);
writer.Write((uint)UncompressedSize);

byte[] nameBytes = EncodeString(Name);
writer.Write((ushort)nameBytes.Length);
Expand Down
4 changes: 2 additions & 2 deletions src/SharpCompress/Common/Zip/Headers/LocalEntryHeader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ internal override void Write(BinaryWriter writer)
writer.Write(LastModifiedTime);
writer.Write(LastModifiedDate);
writer.Write(Crc);
writer.Write(CompressedSize);
writer.Write(UncompressedSize);
writer.Write((uint)CompressedSize);
writer.Write((uint)UncompressedSize);

byte[] nameBytes = EncodeString(Name);

Expand Down

0 comments on commit d0b4af6

Please sign in to comment.