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
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ endif()
#
set(ZLIB_COMPAT ON CACHE BOOL "Build zlib-ng for compatibility with zlib" FORCE)
set(ZLIB_ENABLE_TESTS OFF CACHE BOOL "Do not build zlib-ng tests" FORCE)
set(WITH_NEW_STRATEGIES OFF CACHE BOOL "Disable faster, but with worse compression, deflate strategies" FORCE)

#
# Read product version
Expand Down
2 changes: 1 addition & 1 deletion LibZipSharp.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<_LibZipSharpNugetVersion>2.0.0-alpha4</_LibZipSharpNugetVersion>
<_LibZipSharpNugetVersion>2.0.0-alpha5</_LibZipSharpNugetVersion>
<_NativeBuildDir>$(MSBuildThisFileDirectory)lzsbuild</_NativeBuildDir>
<_ExternalDir>$(MSBuildThisFileDirectory)external</_ExternalDir>
<_MonoPosixNugetVersion>7.0.0-alpha8.21302.6</_MonoPosixNugetVersion>
Expand Down
4 changes: 2 additions & 2 deletions LibZipSharp/Xamarin.Tools.Zip/ZipArchive.cs
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ public ZipEntry AddStream (Stream stream, string archivePath, EntryPermissions p
long index = Native.zip_file_add (archive, destPath, source, overwriteExisting ? OperationFlags.Overwrite : OperationFlags.None);
if (index < 0)
throw GetErrorException ();
if (Native.zip_set_file_compression (archive, (ulong)index, compressionMethod, 0) < 0)
if (Native.zip_set_file_compression (archive, (ulong)index, compressionMethod, 9) < 0)
throw GetErrorException ();
if (permissions == EntryPermissions.Default)
permissions = DefaultFilePermissions;
Expand Down Expand Up @@ -410,7 +410,7 @@ public ZipEntry AddFile (string sourcePath, string archivePath = null,
long index = PlatformServices.Instance.StoreSpecialFile (this, sourcePath, archivePath, out compressionMethod);
if (index < 0)
throw GetErrorException ();
if (Native.zip_set_file_compression (archive, (ulong)index, isDir ? CompressionMethod.Store : compressionMethod, 0) < 0)
if (Native.zip_set_file_compression (archive, (ulong)index, isDir ? CompressionMethod.Store : compressionMethod, 9) < 0)
throw GetErrorException ();
PlatformServices.Instance.SetEntryPermissions (this, sourcePath, (ulong)index, permissions);
ZipEntry entry = ReadEntry ((ulong)index);
Expand Down