Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Synercoding.FileFormats.Pdf/PackageDetails.props
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<Product>Synercoding.FileFormats.Pdf</Product>
<Title>Synercoding.FileFormats.Pdf</Title>
<Description>Contains classes which makes it easy to quickly create a pdf file.</Description>
<PackageReleaseNotes>Added transparent and separation images support. Content streams will be flatedecode encoded. And overprint mode support is added.</PackageReleaseNotes>
<PackageReleaseNotes>Fixed broken zlib stream by removing explicit header and replacing deflate with zlib.</PackageReleaseNotes>
</PropertyGroup>

</Project>
7 changes: 2 additions & 5 deletions src/Synercoding.FileFormats.Pdf/PdfWriter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -275,13 +275,10 @@ internal static Stream FlateEncode(Stream inputStream)
{
var outputStream = new MemoryStream();

outputStream.WriteByte(0x78);
outputStream.WriteByte(0xDA);

inputStream.Position = 0;
using (var flateStream = new DeflateStream(outputStream, CompressionLevel.SmallestSize, true))
using (var zlibStream = new ZLibStream(outputStream, CompressionLevel.SmallestSize, true))
{
inputStream.CopyTo(flateStream);
inputStream.CopyTo(zlibStream);
}

outputStream.Position = 0;
Expand Down