react-native-update 10.34.3 → 10.34.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/harmony/pushy/src/main/cpp/HDiffPatch/CHANGELOG.md +34 -172
- package/harmony/pushy/src/main/cpp/HDiffPatch/LICENSE +4 -4
- package/harmony/pushy/src/main/cpp/HDiffPatch/Makefile +63 -379
- package/harmony/pushy/src/main/cpp/HDiffPatch/README.md +170 -415
- package/harmony/pushy/src/main/cpp/HDiffPatch/_atosize.h +10 -54
- package/harmony/pushy/src/main/cpp/HDiffPatch/_clock_for_demo.h +1 -13
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/Android.mk +18 -171
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/Application.mk +4 -5
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/hpatch.c +7 -38
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/hpatch.h +4 -15
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/hpatch_jni.c +12 -22
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/java/com/github/sisong/HPatch.java +4 -22
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/codeblocks/HDiffPatch.workspace +8 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/codeblocks/HDiffZ.cbp +219 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/codeblocks/HPatchZ.cbp +156 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/codeblocks/unitTest.cbp +65 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/HDiffPatch.sln +105 -155
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/HDiffZ.vcxproj +236 -363
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/HDiffZ.vcxproj.user +3 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/HPatchZ.vcxproj +317 -347
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/HPatchZ.vcxproj.user +3 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/unitTest.vcxproj +181 -295
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/unitTest.vcxproj.user +3 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/HDiffPatch.xcworkspace/contents.xcworkspacedata +0 -9
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/bestParams.xcodeproj/project.pbxproj +14 -53
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/hdiffz.xcodeproj/project.pbxproj +32 -162
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/hpatchz.xcodeproj/project.pbxproj +22 -89
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/lzma.xcodeproj/project.pbxproj +13 -237
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/testHashClash.xcodeproj/project.pbxproj +2 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/unitTest.xcodeproj/project.pbxproj +14 -194
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/zstd.xcodeproj/project.pbxproj +10 -30
- package/harmony/pushy/src/main/cpp/HDiffPatch/checksum_plugin_demo.h +3 -458
- package/harmony/pushy/src/main/cpp/HDiffPatch/compress_parallel.cpp +71 -106
- package/harmony/pushy/src/main/cpp/HDiffPatch/compress_parallel.h +3 -3
- package/harmony/pushy/src/main/cpp/HDiffPatch/compress_plugin_demo.h +110 -484
- package/harmony/pushy/src/main/cpp/HDiffPatch/decompress_plugin_demo.h +193 -835
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/dir_diff.cpp +50 -99
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/dir_diff.h +4 -18
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/dir_diff_tools.cpp +8 -147
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/dir_diff_tools.h +6 -18
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/dir_manifest.cpp +25 -7
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_diff/file_for_dirDiff.h +113 -5
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/dir_patch.c +97 -163
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/dir_patch.h +39 -49
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/dir_patch_tools.c +15 -15
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/dir_patch_tools.h +2 -18
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/dir_patch_types.h +4 -8
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/new_dir_output.c +57 -72
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/new_dir_output.h +13 -18
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/new_stream.c +1 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/new_stream.h +2 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/ref_stream.c +2 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/ref_stream.h +2 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/res_handle_limit.c +2 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/dirDiffPatch/dir_patch/res_handle_limit.h +1 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/file_for_patch.c +100 -311
- package/harmony/pushy/src/main/cpp/HDiffPatch/file_for_patch.h +72 -53
- package/harmony/pushy/src/main/cpp/HDiffPatch/hdiffz.cpp +487 -888
- package/harmony/pushy/src/main/cpp/HDiffPatch/hpatch_dir_listener.h +28 -45
- package/harmony/pushy/src/main/cpp/HDiffPatch/hpatchz.c +247 -812
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/diff.cpp +544 -1265
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/diff.h +38 -123
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/diff_types.h +0 -115
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/bytes_rle.cpp +102 -272
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/bytes_rle.h +12 -22
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/compress_detect.cpp +4 -18
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/compress_detect.h +5 -7
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/{divsufsort.cpp → divsufsort.c} +8 -5
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort.c.inc.h +164 -91
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort.h +102 -5
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort64.c +13 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort64.h +97 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort_private.h +44 -23
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/sssort.c.inc.h +89 -54
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/trsort.c.inc.h +55 -48
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/utils.c.inc.h +381 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/adler_roll.c +47 -110
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/adler_roll.h +4 -11
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/bloom_filter.h +26 -53
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/covers.h +25 -103
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/digest_matcher.cpp +130 -271
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/digest_matcher.h +7 -17
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/stream_serialize.cpp +37 -628
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/stream_serialize.h +43 -203
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/mem_buf.h +10 -14
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/pack_uint.h +7 -22
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/suffix_string.cpp +46 -132
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/suffix_string.h +9 -48
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/patch.c +299 -650
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/patch.h +82 -120
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/patch_private.h +7 -87
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/patch_types.h +9 -119
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_channel.cpp +6 -2
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_channel.h +15 -192
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_import.cpp +367 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_import.h +56 -31
- package/harmony/pushy/src/main/cpp/HDiffPatch/test/_private_searchBestParams.cpp +1 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/test/hpatchz_test.cpp +1 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/test/testHashClash.cpp +31 -225
- package/harmony/pushy/src/main/cpp/HDiffPatch/test/unit_test.cpp +94 -566
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/7zAsm.asm +28 -222
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/7zCrcOpt.asm +117 -228
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/AesOpt.asm +173 -678
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/LzmaDecOpt.asm +22 -103
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/XzCrc64Opt.asm +167 -485
- package/harmony/pushy/src/main/cpp/lzma/C/7z.h +6 -8
- package/harmony/pushy/src/main/cpp/lzma/C/7zAlloc.c +30 -39
- package/harmony/pushy/src/main/cpp/lzma/C/7zAlloc.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/C/7zArcIn.c +217 -232
- package/harmony/pushy/src/main/cpp/lzma/C/7zBuf.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/C/7zCrc.c +68 -404
- package/harmony/pushy/src/main/cpp/lzma/C/7zCrc.h +6 -9
- package/harmony/pushy/src/main/cpp/lzma/C/7zCrcOpt.c +79 -163
- package/harmony/pushy/src/main/cpp/lzma/C/7zDec.c +78 -160
- package/harmony/pushy/src/main/cpp/lzma/C/7zFile.c +58 -215
- package/harmony/pushy/src/main/cpp/lzma/C/7zFile.h +6 -15
- package/harmony/pushy/src/main/cpp/lzma/C/7zStream.c +23 -46
- package/harmony/pushy/src/main/cpp/lzma/C/7zTypes.h +89 -311
- package/harmony/pushy/src/main/cpp/lzma/C/7zVersion.h +5 -5
- package/harmony/pushy/src/main/cpp/lzma/C/Aes.c +68 -191
- package/harmony/pushy/src/main/cpp/lzma/C/Aes.h +8 -30
- package/harmony/pushy/src/main/cpp/lzma/C/AesOpt.c +108 -926
- package/harmony/pushy/src/main/cpp/lzma/C/Alloc.c +96 -246
- package/harmony/pushy/src/main/cpp/lzma/C/Alloc.h +8 -33
- package/harmony/pushy/src/main/cpp/lzma/C/Bcj2.c +144 -177
- package/harmony/pushy/src/main/cpp/lzma/C/Bcj2.h +42 -228
- package/harmony/pushy/src/main/cpp/lzma/C/Bcj2Enc.c +182 -377
- package/harmony/pushy/src/main/cpp/lzma/C/Bra.c +143 -622
- package/harmony/pushy/src/main/cpp/lzma/C/Bra.h +40 -81
- package/harmony/pushy/src/main/cpp/lzma/C/Bra86.c +58 -163
- package/harmony/pushy/src/main/cpp/lzma/C/BraIA64.c +48 -9
- package/harmony/pushy/src/main/cpp/lzma/C/Compiler.h +15 -228
- package/harmony/pushy/src/main/cpp/lzma/C/CpuArch.c +133 -885
- package/harmony/pushy/src/main/cpp/lzma/C/CpuArch.h +78 -428
- package/harmony/pushy/src/main/cpp/lzma/C/Delta.c +31 -136
- package/harmony/pushy/src/main/cpp/lzma/C/Delta.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/C/DllSecur.c +62 -53
- package/harmony/pushy/src/main/cpp/lzma/C/DllSecur.h +5 -5
- package/harmony/pushy/src/main/cpp/lzma/C/LzFind.c +495 -1114
- package/harmony/pushy/src/main/cpp/lzma/C/LzFind.h +25 -64
- package/harmony/pushy/src/main/cpp/lzma/C/LzFindMt.c +400 -969
- package/harmony/pushy/src/main/cpp/lzma/C/LzFindMt.h +24 -37
- package/harmony/pushy/src/main/cpp/lzma/C/LzHash.h +48 -25
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2Dec.c +7 -12
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2Dec.h +7 -8
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2DecMt.c +83 -96
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2DecMt.h +9 -11
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2Enc.c +92 -96
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma2Enc.h +9 -12
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma86.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma86Dec.c +4 -3
- package/harmony/pushy/src/main/cpp/lzma/C/Lzma86Enc.c +6 -3
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaDec.c +206 -384
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaDec.h +8 -11
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaEnc.c +315 -489
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaEnc.h +9 -18
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaLib.c +3 -5
- package/harmony/pushy/src/main/cpp/lzma/C/LzmaLib.h +14 -21
- package/harmony/pushy/src/main/cpp/lzma/C/MtCoder.c +87 -90
- package/harmony/pushy/src/main/cpp/lzma/C/MtCoder.h +25 -28
- package/harmony/pushy/src/main/cpp/lzma/C/MtDec.c +88 -74
- package/harmony/pushy/src/main/cpp/lzma/C/MtDec.h +20 -21
- package/harmony/pushy/src/main/cpp/lzma/C/Ppmd.h +34 -118
- package/harmony/pushy/src/main/cpp/lzma/C/Ppmd7.c +293 -712
- package/harmony/pushy/src/main/cpp/lzma/C/Ppmd7.h +70 -109
- package/harmony/pushy/src/main/cpp/lzma/C/Ppmd7Dec.c +116 -237
- package/harmony/pushy/src/main/cpp/lzma/C/Ppmd7Enc.c +95 -245
- package/harmony/pushy/src/main/cpp/lzma/C/Precomp.h +5 -122
- package/harmony/pushy/src/main/cpp/lzma/C/RotateDefs.h +4 -24
- package/harmony/pushy/src/main/cpp/lzma/C/Sha256.c +143 -387
- package/harmony/pushy/src/main/cpp/lzma/C/Sha256.h +7 -67
- package/harmony/pushy/src/main/cpp/lzma/C/Sort.c +114 -241
- package/harmony/pushy/src/main/cpp/lzma/C/Sort.h +7 -4
- package/harmony/pushy/src/main/cpp/lzma/C/Threads.c +14 -731
- package/harmony/pushy/src/main/cpp/lzma/C/Threads.h +14 -204
- package/harmony/pushy/src/main/cpp/lzma/C/ThreadsP.c +396 -0
- package/harmony/pushy/src/main/cpp/lzma/C/ThreadsP.h +31 -0
- package/harmony/pushy/src/main/cpp/lzma/C/Util/7z/7z.dsp +2 -10
- package/harmony/pushy/src/main/cpp/lzma/C/Util/7z/7zMain.c +79 -282
- package/harmony/pushy/src/main/cpp/lzma/C/Util/7z/Precomp.h +7 -10
- package/harmony/pushy/src/main/cpp/lzma/C/Util/7z/makefile +3 -7
- package/harmony/pushy/src/main/cpp/lzma/C/Util/7z/makefile.gcc +75 -32
- package/harmony/pushy/src/main/cpp/lzma/C/Util/Lzma/LzmaUtil.c +56 -111
- package/harmony/pushy/src/main/cpp/lzma/C/Util/Lzma/LzmaUtil.dsp +0 -24
- package/harmony/pushy/src/main/cpp/lzma/C/Util/Lzma/makefile +0 -2
- package/harmony/pushy/src/main/cpp/lzma/C/Util/Lzma/makefile.gcc +41 -18
- package/harmony/pushy/src/main/cpp/lzma/C/Util/LzmaLib/LzmaLib.dsp +2 -30
- package/harmony/pushy/src/main/cpp/lzma/C/Util/LzmaLib/LzmaLibExports.c +6 -7
- package/harmony/pushy/src/main/cpp/lzma/C/Util/LzmaLib/makefile +2 -27
- package/harmony/pushy/src/main/cpp/lzma/C/Util/SfxSetup/Precomp.h +7 -10
- package/harmony/pushy/src/main/cpp/lzma/C/Util/SfxSetup/SfxSetup.c +22 -39
- package/harmony/pushy/src/main/cpp/lzma/C/Util/SfxSetup/makefile +2 -9
- package/harmony/pushy/src/main/cpp/lzma/C/Util/SfxSetup/makefile_con +1 -3
- package/harmony/pushy/src/main/cpp/lzma/C/Xz.c +3 -5
- package/harmony/pushy/src/main/cpp/lzma/C/Xz.h +47 -129
- package/harmony/pushy/src/main/cpp/lzma/C/XzCrc64.c +43 -97
- package/harmony/pushy/src/main/cpp/lzma/C/XzCrc64.h +8 -8
- package/harmony/pushy/src/main/cpp/lzma/C/XzCrc64Opt.c +36 -228
- package/harmony/pushy/src/main/cpp/lzma/C/XzDec.c +295 -405
- package/harmony/pushy/src/main/cpp/lzma/C/XzEnc.c +139 -194
- package/harmony/pushy/src/main/cpp/lzma/C/XzEnc.h +11 -15
- package/harmony/pushy/src/main/cpp/lzma/C/XzIn.c +134 -200
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/7zip.mak +6 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Aes.mak +1 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zCompressionMode.h +13 -29
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zDecode.cpp +90 -120
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zDecode.h +6 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zEncode.cpp +140 -183
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zEncode.h +20 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zExtract.cpp +57 -78
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zFolderInStream.cpp +44 -169
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zFolderInStream.h +17 -57
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zHandler.cpp +109 -141
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zHandler.h +57 -54
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zHandlerOut.cpp +116 -336
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zHeader.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zHeader.h +9 -17
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zIn.cpp +136 -234
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zIn.h +26 -35
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zItem.h +5 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zOut.cpp +155 -280
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zOut.h +40 -51
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zProperties.cpp +59 -67
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zProperties.h +2 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zRegister.cpp +2 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zSpecStream.cpp +3 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zSpecStream.h +9 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zUpdate.cpp +387 -975
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/7zUpdate.h +16 -44
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/7z/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Archive.def +0 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Archive2.def +0 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/ArchiveExports.cpp +8 -15
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/CoderMixer2.cpp +87 -106
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/CoderMixer2.h +57 -57
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/DummyOutStream.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/DummyOutStream.h +8 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/HandlerOut.cpp +43 -126
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/HandlerOut.h +18 -77
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/InStreamWithCRC.cpp +9 -20
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/InStreamWithCRC.h +23 -20
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/ItemNameUtils.cpp +9 -61
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/ItemNameUtils.h +3 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/MultiStream.cpp +27 -29
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/MultiStream.h +26 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/OutStreamWithCRC.cpp +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/OutStreamWithCRC.h +8 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/ParseProperties.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/Common/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/DllExports2.cpp +10 -63
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/IArchive.h +173 -319
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/LzmaHandler.cpp +113 -92
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/SplitHandler.cpp +53 -47
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/XzHandler.cpp +208 -352
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Archive/XzHandler.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Asm.mak +3 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Alone7z/Alone.dsp +47 -227
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Alone7z/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Alone7z/makefile +5 -19
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Format7zExtractR/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Format7zExtractR/makefile +2 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Format7zR/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Format7zR/makefile +1 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/LzmaCon/LzmaAlone.cpp +53 -71
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/LzmaCon/LzmaCon.dsp +22 -85
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/LzmaCon/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/LzmaCon/makefile +4 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/LzmaCon/makefile.gcc +166 -102
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/SFXCon.dsp +4 -109
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/SfxCon.cpp +30 -69
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/makefile +7 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/resource.rc +1 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.cpp +16 -16
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/ExtractCallbackSfx.h +12 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/ExtractEngine.cpp +9 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/ExtractEngine.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/SFXSetup.dsp +5 -74
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp +51 -58
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/StdAfx.h +10 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXSetup/makefile +5 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXWin/SFXWin.dsp +6 -92
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXWin/SfxWin.cpp +19 -46
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXWin/StdAfx.h +11 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXWin/makefile +5 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXWin/resource.rc +0 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/CWrappers.cpp +28 -136
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/CWrappers.h +5 -67
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/CreateCoder.cpp +62 -74
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/CreateCoder.h +24 -32
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FilePathAutoRename.cpp +7 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FilePathAutoRename.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FileStreams.cpp +100 -548
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FileStreams.h +86 -125
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FilterCoder.cpp +116 -258
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/FilterCoder.h +76 -72
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/InBuffer.cpp +15 -34
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/InBuffer.h +9 -38
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/InOutTempBuffer.cpp +82 -192
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/InOutTempBuffer.h +28 -25
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/LimitedStreams.cpp +52 -78
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/LimitedStreams.h +83 -52
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/LockedStream.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/MethodId.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/MethodProps.cpp +67 -323
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/MethodProps.h +38 -123
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/OffsetStream.cpp +8 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/OffsetStream.h +13 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/OutBuffer.cpp +12 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/OutBuffer.h +7 -74
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/ProgressUtils.cpp +5 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/ProgressUtils.h +13 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/PropId.cpp +1 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/RegisterArc.h +14 -16
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/RegisterCodec.h +16 -16
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamBinder.cpp +50 -45
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamBinder.h +21 -39
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamObjects.cpp +42 -47
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamObjects.h +53 -42
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamUtils.cpp +4 -49
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/StreamUtils.h +2 -20
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/UniqBlocks.cpp +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/UniqBlocks.h +5 -20
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/VirtThread.cpp +9 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/VirtThread.h +5 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Bcj2Coder.cpp +355 -556
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Bcj2Coder.h +59 -66
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Bcj2Register.cpp +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BcjCoder.cpp +6 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BcjCoder.h +13 -19
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BcjRegister.cpp +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BranchMisc.cpp +5 -88
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BranchMisc.h +18 -42
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/BranchRegister.cpp +16 -33
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/ByteSwap.cpp +53 -52
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/CodecExports.cpp +30 -64
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/CopyCoder.cpp +22 -55
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/CopyCoder.h +26 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/DeltaFilter.cpp +28 -26
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Lzma2Decoder.cpp +28 -30
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Lzma2Decoder.h +54 -45
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Lzma2Encoder.cpp +12 -24
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Lzma2Encoder.h +22 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/Lzma2Register.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/LzmaDecoder.cpp +26 -33
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/LzmaDecoder.h +51 -51
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/LzmaEncoder.cpp +40 -232
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/LzmaEncoder.h +14 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/LzmaRegister.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/PpmdDecoder.cpp +35 -84
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/PpmdDecoder.h +41 -42
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/PpmdEncoder.cpp +25 -66
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/PpmdEncoder.h +17 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/PpmdRegister.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/XzDecoder.cpp +12 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/XzDecoder.h +32 -26
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/XzEncoder.cpp +16 -14
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Compress/XzEncoder.h +20 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crc.mak +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crc64.mak +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/7zAes.cpp +32 -67
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/7zAes.h +18 -30
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/7zAesRegister.cpp +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/MyAes.cpp +43 -208
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/MyAes.h +25 -90
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/MyAesReg.cpp +4 -17
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/RandGen.cpp +21 -29
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/RandGen.h +3 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Crypto/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/GuiCommon.rc +3 -38
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Guid.txt +3 -26
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/ICoder.h +172 -253
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/IDecl.h +7 -55
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/IPassword.h +12 -43
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/IProgress.h +9 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/IStream.h +50 -133
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/LzmaDec.mak +2 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/MyVersionInfo.rc +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/PropID.h +2 -53
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Client7z/Client7z.cpp +177 -329
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Client7z/Client7z.dsp +1 -97
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Client7z/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Client7z/makefile +1 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveCommandLine.cpp +183 -687
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveCommandLine.h +15 -49
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveExtractCallback.cpp +913 -2275
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveExtractCallback.h +115 -353
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveName.cpp +106 -127
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveName.h +3 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveOpenCallback.cpp +35 -272
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ArchiveOpenCallback.h +64 -134
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Bench.cpp +1200 -2608
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Bench.h +20 -64
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/DefaultName.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/DefaultName.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/DirItem.h +36 -253
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/EnumDirItems.cpp +233 -774
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/EnumDirItems.h +6 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ExitCode.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Extract.cpp +63 -156
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Extract.h +10 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ExtractMode.h +2 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ExtractingFilePath.cpp +6 -22
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ExtractingFilePath.h +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/HashCalc.cpp +65 -1991
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/HashCalc.h +29 -241
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/IFileExtractCallback.h +47 -45
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/LoadCodecs.cpp +179 -442
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/LoadCodecs.h +89 -147
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/OpenArchive.cpp +380 -529
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/OpenArchive.h +42 -75
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/PropIDUtils.cpp +86 -163
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/PropIDUtils.h +5 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Property.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/SetProperties.cpp +15 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/SetProperties.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/SortUtils.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/TempFiles.cpp +1 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/TempFiles.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Update.cpp +368 -595
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/Update.h +47 -68
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdateAction.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdateCallback.cpp +146 -444
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdateCallback.h +68 -103
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdatePair.cpp +42 -111
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdatePair.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdateProduce.cpp +3 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/UpdateProduce.h +6 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/WorkDir.cpp +35 -25
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/WorkDir.h +4 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Common/ZipRegistry.h +9 -91
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/BenchCon.cpp +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/BenchCon.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/Console.mak +1 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/Console.manifest +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/ConsoleClose.cpp +19 -48
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/ConsoleClose.h +12 -18
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/ExtractCallbackConsole.cpp +41 -162
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/ExtractCallbackConsole.h +41 -88
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/HashCon.cpp +81 -140
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/HashCon.h +17 -27
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/List.cpp +124 -182
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/List.h +7 -22
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/Main.cpp +109 -590
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/MainAr.cpp +2 -62
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/OpenCallbackConsole.cpp +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/OpenCallbackConsole.h +10 -17
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/PercentPrinter.cpp +10 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/PercentPrinter.h +9 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/UpdateCallbackConsole.cpp +24 -320
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/UpdateCallbackConsole.h +26 -50
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/UserInputUtils.cpp +5 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/UserInputUtils.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/makefile +2 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Explorer/MyMessages.cpp +6 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Explorer/MyMessages.h +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/BrowseDialog.cpp +195 -302
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/BrowseDialog.h +4 -15
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ComboDialog.cpp +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ComboDialog.h +6 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/DialogSize.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ExtractCallback.cpp +181 -416
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ExtractCallback.h +197 -216
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/FormatUtils.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/LangUtils.h +5 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/MyWindowsNew.h +5 -48
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/OverwriteDialog.cpp +49 -215
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/OverwriteDialog.h +30 -50
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/OverwriteDialog.rc +1 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/OverwriteDialogRes.h +3 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/PasswordDialog.cpp +5 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/PasswordDialog.h +6 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/PasswordDialog.rc +0 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog.cpp +10 -15
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog.h +17 -18
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog2.cpp +130 -276
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog2.h +52 -56
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog2Res.h +1 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/ProgressDialog2a.rc +3 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/PropertyName.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/PropertyNameRes.h +0 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/SysIconUtils.cpp +89 -185
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/SysIconUtils.h +20 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/resource.h +1 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/resourceGui.h +0 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/Extract.rc +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/ExtractDialog.cpp +33 -36
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/ExtractDialog.h +15 -15
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/ExtractGUI.cpp +22 -39
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/ExtractGUI.h +3 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/HashGUI.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Build.mak +13 -109
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/AutoPtr.h +14 -25
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/CRC.cpp +1 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/C_FileIO.cpp +90 -1
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/C_FileIO.h +49 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/ComTry.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/CommandLineParser.cpp +7 -41
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/CommandLineParser.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Common.h +29 -14
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/CrcReg.cpp +45 -24
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Defs.h +2 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/DynamicBuffer.h +5 -17
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/IntToString.cpp +110 -132
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/IntToString.h +9 -35
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Lang.h +5 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/ListFileUtils.cpp +31 -49
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/ListFileUtils.h +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyBuffer.h +21 -59
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyBuffer2.h +10 -95
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyCom.h +81 -497
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyException.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyGuidDef.h +9 -18
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyInitGuid.h +5 -17
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyLinux.h +2 -35
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyString.cpp +164 -347
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyString.h +35 -246
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyTypes.h +8 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyUnknown.h +11 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyVector.h +94 -184
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyWindows.cpp +11 -158
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/MyWindows.h +54 -148
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/NewHandler.cpp +27 -204
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/NewHandler.h +5 -38
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Sha256Reg.cpp +16 -43
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StdAfx.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StdInStream.cpp +11 -20
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StdInStream.h +5 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StdOutStream.cpp +39 -124
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StdOutStream.h +11 -27
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StringConvert.cpp +15 -458
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StringConvert.h +2 -24
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StringToInt.cpp +89 -99
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/StringToInt.h +2 -19
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/TextConfig.cpp +11 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/TextConfig.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/UTFConvert.cpp +102 -677
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/UTFConvert.h +5 -377
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Wildcard.cpp +84 -197
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Wildcard.h +25 -107
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/XzCrc64Reg.cpp +14 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/COM.h +8 -24
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/CommonDialog.cpp +113 -197
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/CommonDialog.h +12 -32
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ComboBox.cpp +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ComboBox.h +10 -22
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/CommandBar.h +6 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Dialog.cpp +47 -242
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Dialog.h +51 -94
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Edit.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ImageList.h +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ListView.cpp +26 -33
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ListView.h +22 -32
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ProgressBar.h +13 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/PropertyPage.cpp +34 -56
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/PropertyPage.h +9 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ReBar.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Static.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/StatusBar.h +5 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/ToolBar.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Trackbar.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Window2.cpp +6 -8
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Control/Window2.h +7 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/DLL.cpp +8 -77
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/DLL.h +10 -55
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Defs.h +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/ErrorMsg.cpp +2 -69
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/ErrorMsg.h +2 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileDir.cpp +80 -728
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileDir.h +7 -62
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileFind.cpp +56 -756
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileFind.h +19 -205
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileIO.cpp +47 -569
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileIO.h +28 -283
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileLink.cpp +112 -369
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileMapping.h +3 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileName.cpp +113 -185
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileName.h +14 -41
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileSystem.cpp +10 -66
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/FileSystem.h +2 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Handle.h +4 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/MemoryLock.cpp +14 -29
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/MemoryLock.h +2 -2
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/NtCheck.h +2 -14
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/PropVariant.cpp +56 -102
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/PropVariant.h +9 -68
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/PropVariantConv.cpp +14 -150
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/PropVariantConv.h +3 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Registry.cpp +128 -212
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Registry.h +20 -32
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/ResourceString.cpp +4 -4
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/ResourceString.h +2 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/SecurityUtils.cpp +18 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/SecurityUtils.h +56 -39
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Shell.cpp +58 -539
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Shell.h +14 -49
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/StdAfx.h +2 -5
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Synchronization.cpp +0 -77
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Synchronization.h +18 -240
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/System.cpp +38 -317
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/System.h +5 -154
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Thread.h +10 -18
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/TimeUtils.cpp +37 -291
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/TimeUtils.h +10 -124
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Window.cpp +7 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Window.h +19 -98
- package/harmony/pushy/src/main/cpp/lzma/CS/7zip/Compress/LzmaAlone/LzmaAlone.csproj +90 -0
- package/harmony/pushy/src/main/cpp/lzma/DOC/Methods.txt +2 -6
- package/harmony/pushy/src/main/cpp/lzma/DOC/lzma-history.txt +0 -205
- package/harmony/pushy/src/main/cpp/lzma/DOC/lzma-sdk.txt +13 -93
- package/harmony/pushy/src/main/cpp/lzma/DOC/lzma.txt +13 -30
- package/harmony/pushy/src/main/cpp/lzma/bin/7zS2.sfx +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/7zS2con.sfx +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/7zSD.sfx +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/7zdec.exe +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/7zr.exe +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/lzma.exe +0 -0
- package/harmony/pushy/src/main/cpp/lzma/bin/x64/7zr.exe +0 -0
- package/package.json +1 -1
- package/react-native-update.podspec +0 -1
- package/react-native.config.js +1 -0
- package/src/client.ts +1 -2
- package/src/type.ts +1 -0
- package/harmony/pushy/src/main/cpp/HDiffPatch/README_cn.md +0 -547
- package/harmony/pushy/src/main/cpp/HDiffPatch/_hextobytes.h +0 -112
- package/harmony/pushy/src/main/cpp/HDiffPatch/bsdiff_wrapper/bsdiff_wrapper.cpp +0 -389
- package/harmony/pushy/src/main/cpp/HDiffPatch/bsdiff_wrapper/bsdiff_wrapper.h +0 -73
- package/harmony/pushy/src/main/cpp/HDiffPatch/bsdiff_wrapper/bspatch_wrapper.c +0 -266
- package/harmony/pushy/src/main/cpp/HDiffPatch/bsdiff_wrapper/bspatch_wrapper.h +0 -58
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/build_libs_patchers.bat +0 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/android_ndk_jni_mk/build_libs_patchers.sh +0 -1
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/bzip2.vcxproj +0 -228
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/hpatchz_test.vcxproj +0 -215
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/libdeflate.vcxproj +0 -256
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/longPathAware.exe.manifest +0 -7
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/lzma.vcxproj +0 -271
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/testHashClash.vcxproj +0 -228
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/zlib.vcxproj +0 -242
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/vc/zstd.vcxproj +0 -287
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/HDiffPatch.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +0 -8
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/libdeflate.xcodeproj/project.pbxproj +0 -286
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode/zlib.xcodeproj/project.pbxproj +0 -308
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode_iOS_hpatchz/hpatch_objc/hpatch_objc.h +0 -33
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode_iOS_hpatchz/hpatch_objc/hpatch_objc.m +0 -33
- package/harmony/pushy/src/main/cpp/HDiffPatch/builds/xcode_iOS_hpatchz/hpatchz.xcodeproj/project.pbxproj +0 -774
- package/harmony/pushy/src/main/cpp/HDiffPatch/hdiffz_import_patch.c +0 -31
- package/harmony/pushy/src/main/cpp/HDiffPatch/hdiffz_import_patch.h +0 -42
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/diff_for_hpatch_lite.h +0 -74
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/match_block.cpp +0 -478
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/match_block.h +0 -222
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/libdivsufsort/divsufsort64.cpp +0 -14
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/match_inplace.cpp +0 -168
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/match_inplace.h +0 -44
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HDiff/private_diff/qsort_parallel.h +0 -125
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hcache_old_mt.c +0 -243
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hcache_old_mt.h +0 -51
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hinput_mt.c +0 -153
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hinput_mt.h +0 -54
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_houtput_mt.c +0 -158
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_houtput_mt.h +0 -49
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hpatch_mt.c +0 -294
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_hpatch_mt.h +0 -59
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/_patch_private_mt.h +0 -217
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/hpatch_mt.c +0 -349
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatch/hpatch_mt/hpatch_mt.h +0 -110
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatchLite/hpatch_lite.c +0 -366
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatchLite/hpatch_lite.h +0 -91
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatchLite/hpatch_lite_input_cache.h +0 -31
- package/harmony/pushy/src/main/cpp/HDiffPatch/libHDiffPatch/HPatchLite/hpatch_lite_types.h +0 -106
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_import_c.c +0 -497
- package/harmony/pushy/src/main/cpp/HDiffPatch/libParallel/parallel_import_c.h +0 -106
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sign_diff/_match_in_old_sign.cpp +0 -254
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sign_diff/_match_in_old_sign.h +0 -39
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sign_diff/_sign_diff_type.h +0 -37
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sign_diff/sign_diff.cpp +0 -62
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sign_diff/sign_diff.h +0 -44
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/dict_decompress_plugin.h +0 -156
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/dir_sync_client.cpp +0 -440
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/dir_sync_client.h +0 -88
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/match_in_old.cpp +0 -332
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/match_in_old.h +0 -48
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/match_in_types.h +0 -198
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_client.cpp +0 -697
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_client.h +0 -74
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_client_private.h +0 -262
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_client_type.h +0 -174
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_client_type_private.h +0 -174
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_diff_data.cpp +0 -252
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_diff_data.h +0 -67
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_info_client.cpp +0 -680
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_client/sync_info_client.h +0 -137
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/dict_compress_plugin.h +0 -83
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/dir_sync_make.cpp +0 -125
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/dir_sync_make.h +0 -56
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/hsynz_plugin.h +0 -55
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/match_in_new.cpp +0 -147
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/match_in_new.h +0 -38
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_info_make.cpp +0 -354
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_info_make.h +0 -76
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_make.cpp +0 -521
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_make.h +0 -69
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_make_hash_clash.h +0 -122
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/sync_make/sync_make_private.h +0 -66
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_client_type.h +0 -36
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_client_type_private.h +0 -81
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_client_wrapper.cpp +0 -247
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_client_wrapper.h +0 -71
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_info_client.cpp +0 -351
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_info_client.h +0 -42
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_match_in_old.cpp +0 -124
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_client_wrapper/zsync_match_in_old.h +0 -38
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_make_wrapper/zsync_info_make.cpp +0 -203
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_make_wrapper/zsync_info_make.h +0 -55
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_make_wrapper/zsync_make_wrapper.cpp +0 -79
- package/harmony/pushy/src/main/cpp/HDiffPatch/libhsync/zsync_make_wrapper/zsync_make_wrapper.h +0 -66
- package/harmony/pushy/src/main/cpp/HDiffPatch/vcdiff_wrapper/vcdiff_wrapper.cpp +0 -628
- package/harmony/pushy/src/main/cpp/HDiffPatch/vcdiff_wrapper/vcdiff_wrapper.h +0 -95
- package/harmony/pushy/src/main/cpp/HDiffPatch/vcdiff_wrapper/vcpatch_code_table.h +0 -78
- package/harmony/pushy/src/main/cpp/HDiffPatch/vcdiff_wrapper/vcpatch_wrapper.c +0 -950
- package/harmony/pushy/src/main/cpp/HDiffPatch/vcdiff_wrapper/vcpatch_wrapper.h +0 -72
- package/harmony/pushy/src/main/cpp/lzma/Asm/arm64/7zAsm.S +0 -181
- package/harmony/pushy/src/main/cpp/lzma/Asm/arm64/LzmaDecOpt.S +0 -1487
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/LzFindOpt.asm +0 -540
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/Sha256Opt.asm +0 -275
- package/harmony/pushy/src/main/cpp/lzma/Asm/x86/Sort.asm +0 -860
- package/harmony/pushy/src/main/cpp/lzma/C/7zWindows.h +0 -101
- package/harmony/pushy/src/main/cpp/lzma/C/7zip_gcc_c.mak +0 -360
- package/harmony/pushy/src/main/cpp/lzma/C/Asm_c.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/C/LzFindOpt.c +0 -578
- package/harmony/pushy/src/main/cpp/lzma/C/Sha256Opt.c +0 -451
- package/harmony/pushy/src/main/cpp/lzma/C/SwapBytes.c +0 -835
- package/harmony/pushy/src/main/cpp/lzma/C/SwapBytes.h +0 -17
- package/harmony/pushy/src/main/cpp/lzma/C/Util/Lzma/Precomp.h +0 -13
- package/harmony/pushy/src/main/cpp/lzma/C/Util/LzmaLib/Precomp.c +0 -4
- package/harmony/pushy/src/main/cpp/lzma/C/Util/LzmaLib/Precomp.h +0 -13
- package/harmony/pushy/src/main/cpp/lzma/C/var_clang.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/C/var_clang_arm64.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/C/var_clang_x64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/C/var_clang_x86.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/C/var_gcc.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/C/var_gcc_arm64.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/C/var_gcc_x64.mak +0 -10
- package/harmony/pushy/src/main/cpp/lzma/C/var_gcc_x86.mak +0 -10
- package/harmony/pushy/src/main/cpp/lzma/C/var_mac_arm64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/C/var_mac_x64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/C/warn_clang.mak +0 -1
- package/harmony/pushy/src/main/cpp/lzma/C/warn_clang_mac.mak +0 -1
- package/harmony/pushy/src/main/cpp/lzma/C/warn_gcc.mak +0 -51
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/7zip_gcc.mak +0 -1370
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/Alone7z/makefile.gcc +0 -279
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Bundles/SFXCon/makefile.gcc +0 -215
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/MultiOutStream.cpp +0 -855
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Common/MultiOutStream.h +0 -160
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/LzFindOpt.mak +0 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/LzmaDec_gcc.mak +0 -14
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Sha256.mak +0 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/Sort.mak +0 -6
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Client7z/makefile.gcc +0 -72
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/Console/makefile.gcc +0 -187
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/MemDialog.cpp +0 -218
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/MemDialog.h +0 -48
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/MemDialogRes.h +0 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/FileManager/StdAfx.h +0 -67
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/UI/GUI/7zG.exe.manifest +0 -23
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_clang.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_clang_arm64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_clang_x64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_clang_x86.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_gcc.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_gcc_arm64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_gcc_x64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_gcc_x86.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_mac_arm64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/cmpl_mac_x64.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_clang.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_clang_arm64.mak +0 -19
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_clang_x64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_clang_x86.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_gcc.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_gcc_arm64.mak +0 -12
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_gcc_x64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_gcc_x86.mak +0 -10
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_mac_arm64.mak +0 -13
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/var_mac_x64.mak +0 -11
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/warn_clang.mak +0 -3
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/warn_clang_mac.mak +0 -9
- package/harmony/pushy/src/main/cpp/lzma/CPP/7zip/warn_gcc.mak +0 -55
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Common0.h +0 -330
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/DynLimBuf.cpp +0 -93
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/DynLimBuf.h +0 -41
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/LzFindPrepare.cpp +0 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/Common/Sha256Prepare.cpp +0 -7
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Clipboard.cpp +0 -130
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/Clipboard.h +0 -28
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/MemoryGlobal.cpp +0 -36
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/MemoryGlobal.h +0 -55
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/SystemInfo.cpp +0 -1251
- package/harmony/pushy/src/main/cpp/lzma/CPP/Windows/SystemInfo.h +0 -19
- package/ios/ImportReact.h +0 -2
|
@@ -28,10 +28,8 @@
|
|
|
28
28
|
#ifndef HDiff_compress_plugin_demo_h
|
|
29
29
|
#define HDiff_compress_plugin_demo_h
|
|
30
30
|
//compress plugin demo:
|
|
31
|
-
// zlibCompressPlugin
|
|
32
|
-
// pzlibCompressPlugin
|
|
33
|
-
// ldefCompressPlugin // compatible with zlib's deflate encoding
|
|
34
|
-
// pldefCompressPlugin // compatible with zlib's deflate encoding
|
|
31
|
+
// zlibCompressPlugin
|
|
32
|
+
// pzlibCompressPlugin
|
|
35
33
|
// bz2CompressPlugin
|
|
36
34
|
// pbz2CompressPlugin
|
|
37
35
|
// lzmaCompressPlugin
|
|
@@ -41,9 +39,6 @@
|
|
|
41
39
|
// zstdCompressPlugin
|
|
42
40
|
// brotliCompressPlugin
|
|
43
41
|
// lzhamCompressPlugin
|
|
44
|
-
// tuzCompressPlugin
|
|
45
|
-
|
|
46
|
-
// _7zXZCompressPlugin : support for create_vcdiff(), compatible with "xdelta3 -S lzma ..."
|
|
47
42
|
|
|
48
43
|
#include "libHDiffPatch/HDiff/diff_types.h"
|
|
49
44
|
#include "compress_parallel.h"
|
|
@@ -103,16 +98,13 @@ static const char* _fun_name(void){ \
|
|
|
103
98
|
return kCompressType; \
|
|
104
99
|
}
|
|
105
100
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
hpatch_StreamPos_t result=dataSize+(dataSize>>3)+256;
|
|
101
|
+
hpatch_inline static
|
|
102
|
+
hpatch_StreamPos_t _default_maxCompressedSize(hpatch_StreamPos_t dataSize){
|
|
103
|
+
hpatch_StreamPos_t result=dataSize+(dataSize>>3)+1024*2;
|
|
110
104
|
assert(result>dataSize);
|
|
111
105
|
return result;
|
|
112
106
|
}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
static
|
|
107
|
+
hpatch_inline static
|
|
116
108
|
int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadNum){
|
|
117
109
|
return 1;
|
|
118
110
|
}
|
|
@@ -125,7 +117,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
125
117
|
hdiff_TCompress base;
|
|
126
118
|
int compress_level; //0..9
|
|
127
119
|
int mem_level;
|
|
128
|
-
signed char windowBits;
|
|
120
|
+
signed char windowBits;
|
|
129
121
|
hpatch_BOOL isNeedSaveWindowBits;
|
|
130
122
|
int strategy;
|
|
131
123
|
} TCompressPlugin_zlib;
|
|
@@ -136,43 +128,36 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
136
128
|
z_stream c_stream;
|
|
137
129
|
} _zlib_TCompress;
|
|
138
130
|
|
|
139
|
-
static _zlib_TCompress*
|
|
131
|
+
static _zlib_TCompress* _zlib_compress_open_by(const hdiff_TCompress* compressPlugin,
|
|
140
132
|
int compressLevel,int compressMemLevel,
|
|
141
133
|
const hpatch_TStreamOutput* out_code,
|
|
142
|
-
|
|
134
|
+
unsigned char* _mem_buf,size_t _mem_buf_size){
|
|
143
135
|
const TCompressPlugin_zlib* plugin=(const TCompressPlugin_zlib*)compressPlugin;
|
|
144
|
-
|
|
136
|
+
_zlib_TCompress* self=0;
|
|
137
|
+
|
|
138
|
+
self=(_zlib_TCompress*)_hpatch_align_upper(_mem_buf,sizeof(hpatch_StreamPos_t));
|
|
139
|
+
assert((_mem_buf+_mem_buf_size)>((unsigned char*)self+sizeof(_zlib_TCompress)));
|
|
140
|
+
_mem_buf_size=(_mem_buf+_mem_buf_size)-((unsigned char*)self+sizeof(_zlib_TCompress));
|
|
141
|
+
_mem_buf=(unsigned char*)self+sizeof(_zlib_TCompress);
|
|
142
|
+
|
|
145
143
|
memset(self,0,sizeof(_zlib_TCompress));
|
|
146
|
-
self->c_buf=
|
|
147
|
-
self->c_buf_size=
|
|
144
|
+
self->c_buf=_mem_buf;
|
|
145
|
+
self->c_buf_size=_mem_buf_size;
|
|
148
146
|
self->out_code=out_code;
|
|
149
147
|
|
|
150
|
-
self->c_stream.next_out = (Bytef*)
|
|
151
|
-
self->c_stream.avail_out = (uInt)
|
|
148
|
+
self->c_stream.next_out = (Bytef*)_mem_buf;
|
|
149
|
+
self->c_stream.avail_out = (uInt)_mem_buf_size;
|
|
152
150
|
if (Z_OK!=deflateInit2(&self->c_stream,compressLevel,Z_DEFLATED,
|
|
153
151
|
plugin->windowBits,compressMemLevel,plugin->strategy))
|
|
154
152
|
return 0;
|
|
155
153
|
return self;
|
|
156
154
|
}
|
|
157
|
-
static
|
|
158
|
-
|
|
159
|
-
const hpatch_TStreamOutput* out_code,
|
|
160
|
-
unsigned char* _mem_buf,size_t _mem_buf_size){
|
|
161
|
-
#define __MAX_TS(a,b) ((a)>=(b)?(a):(b))
|
|
162
|
-
const hpatch_size_t kZlibAlign=__MAX_TS(__MAX_TS(sizeof(hpatch_StreamPos_t),sizeof(void*)),sizeof(uLongf));
|
|
163
|
-
#undef __MAX_TS
|
|
164
|
-
unsigned char* _mem_buf_end=_mem_buf+_mem_buf_size;
|
|
165
|
-
unsigned char* self_at=(unsigned char*)_hpatch_align_upper(_mem_buf,kZlibAlign);
|
|
166
|
-
if (self_at>=_mem_buf_end) return 0;
|
|
167
|
-
return _zlib_compress_open_at(compressPlugin,compressLevel,compressMemLevel,out_code,
|
|
168
|
-
(_zlib_TCompress*)self_at,_mem_buf_end-self_at);
|
|
169
|
-
}
|
|
170
|
-
static hpatch_BOOL _zlib_compress_close_by(const hdiff_TCompress* compressPlugin,_zlib_TCompress* self){
|
|
171
|
-
hpatch_BOOL result=hpatch_TRUE;
|
|
155
|
+
static int _zlib_compress_close_by(const hdiff_TCompress* compressPlugin,_zlib_TCompress* self){
|
|
156
|
+
int result=1;//true;
|
|
172
157
|
if (!self) return result;
|
|
173
158
|
if (self->c_stream.state!=0){
|
|
174
159
|
int ret=deflateEnd(&self->c_stream);
|
|
175
|
-
result=(Z_OK==ret)
|
|
160
|
+
result=(Z_OK==ret);
|
|
176
161
|
}
|
|
177
162
|
memset(self,0,sizeof(_zlib_TCompress));
|
|
178
163
|
return result;
|
|
@@ -237,11 +222,11 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
237
222
|
data_buf=_temp_buf+sizeof(_zlib_TCompress)+kCompressBufSize;
|
|
238
223
|
if (!self) _compress_error_return("deflateInit2()");
|
|
239
224
|
if (plugin->isNeedSaveWindowBits){
|
|
240
|
-
|
|
225
|
+
unsigned char* pchar=(unsigned char*)&plugin->windowBits;
|
|
241
226
|
if (!out_code->write(out_code,0,pchar,pchar+1)) _compress_error_return("out_code->write()");
|
|
242
227
|
++result;
|
|
243
228
|
}
|
|
244
|
-
|
|
229
|
+
do {
|
|
245
230
|
size_t readLen=kCompressBufSize;
|
|
246
231
|
if (readLen>(hpatch_StreamPos_t)(in_data->streamSize-readFromPos))
|
|
247
232
|
readLen=(size_t)(in_data->streamSize-readFromPos);
|
|
@@ -251,7 +236,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
251
236
|
if (!_zlib_compress_part(self,data_buf,data_buf+readLen,
|
|
252
237
|
(readFromPos==in_data->streamSize),&result,&outStream_isCanceled))
|
|
253
238
|
_compress_error_return("_zlib_compress_part()");
|
|
254
|
-
}
|
|
239
|
+
} while (readFromPos<in_data->streamSize);
|
|
255
240
|
clear:
|
|
256
241
|
if (!_zlib_compress_close_by(compressPlugin,self))
|
|
257
242
|
{ result=kCompressFailResult; if (strlen(errAt)==0) errAt="deflateEnd()"; }
|
|
@@ -276,90 +261,49 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
276
261
|
plugin->thread_num=threadNum;
|
|
277
262
|
return threadNum;
|
|
278
263
|
}
|
|
264
|
+
static hdiff_compressBlockHandle _pzlib_openBlockCompressor(hdiff_TParallelCompress* pc){
|
|
265
|
+
return pc;
|
|
266
|
+
}
|
|
279
267
|
static void _pzlib_closeBlockCompressor(hdiff_TParallelCompress* pc,
|
|
280
268
|
hdiff_compressBlockHandle blockCompressor){
|
|
281
|
-
|
|
282
|
-
if (!stream) return;
|
|
283
|
-
if (stream->state!=0){
|
|
284
|
-
int ret=deflateEnd(stream);
|
|
285
|
-
assert((Z_OK==ret)|(Z_DATA_ERROR==ret));
|
|
286
|
-
}
|
|
287
|
-
free(stream);
|
|
288
|
-
}
|
|
289
|
-
static hdiff_compressBlockHandle _pzlib_openBlockCompressor(hdiff_TParallelCompress* pc){
|
|
290
|
-
const TCompressPlugin_pzlib* plugin=(const TCompressPlugin_pzlib*)pc->import;
|
|
291
|
-
z_stream* stream=(z_stream*)malloc(sizeof(z_stream));
|
|
292
|
-
if (!stream) return 0;
|
|
293
|
-
memset(stream,0,sizeof(z_stream));
|
|
294
|
-
int err = deflateInit2(stream,plugin->base.compress_level,Z_DEFLATED,
|
|
295
|
-
plugin->base.windowBits,plugin->base.mem_level,Z_DEFAULT_STRATEGY);
|
|
296
|
-
if (err!=Z_OK){//error
|
|
297
|
-
_pzlib_closeBlockCompressor(pc,stream);
|
|
298
|
-
return 0;
|
|
299
|
-
}
|
|
300
|
-
return stream;
|
|
269
|
+
assert(blockCompressor==pc);
|
|
301
270
|
}
|
|
302
|
-
static int _pzlib_compress2(Bytef* dest,uLongf* destLen,const
|
|
303
|
-
|
|
304
|
-
|
|
271
|
+
static int _pzlib_compress2(Bytef* dest,uLongf* destLen,const Bytef* source,uLong sourceLen,
|
|
272
|
+
int level,int mem_level,int windowBits){
|
|
273
|
+
z_stream stream;
|
|
305
274
|
int err;
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
stream
|
|
310
|
-
stream
|
|
311
|
-
stream
|
|
312
|
-
stream
|
|
313
|
-
|
|
314
|
-
if (
|
|
315
|
-
|
|
316
|
-
|
|
275
|
+
stream.next_in = (Bytef *)source;
|
|
276
|
+
stream.avail_in = (uInt)sourceLen;
|
|
277
|
+
stream.next_out = dest;
|
|
278
|
+
stream.avail_out = (uInt)*destLen;
|
|
279
|
+
stream.zalloc = 0;
|
|
280
|
+
stream.zfree = 0;
|
|
281
|
+
stream.opaque = 0;
|
|
282
|
+
err = deflateInit2(&stream,level,Z_DEFLATED,windowBits,mem_level,Z_DEFAULT_STRATEGY);
|
|
283
|
+
if (err != Z_OK) return err;
|
|
284
|
+
err = deflate(&stream, Z_FINISH);
|
|
285
|
+
if (err != Z_STREAM_END){
|
|
286
|
+
deflateEnd(&stream);
|
|
287
|
+
return err == Z_OK ? Z_BUF_ERROR : err;
|
|
317
288
|
}
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
err = deflate(stream,Z_BLOCK);
|
|
321
|
-
_check_zlib_err(Z_OK);
|
|
322
|
-
// add enough empty blocks to get to a byte boundary
|
|
323
|
-
err = deflatePending(stream,Z_NULL,&bits);
|
|
324
|
-
_check_zlib_err(Z_OK);
|
|
325
|
-
if (bits & 1){
|
|
326
|
-
err = deflate(stream,Z_SYNC_FLUSH);
|
|
327
|
-
_check_zlib_err(Z_OK);
|
|
328
|
-
} else if (bits & 7) {
|
|
329
|
-
do { // add static empty blocks
|
|
330
|
-
err = deflatePrime(stream, 10, 2);
|
|
331
|
-
_check_zlib_err(Z_OK);
|
|
332
|
-
err = deflatePending(stream,Z_NULL,&bits);
|
|
333
|
-
_check_zlib_err(Z_OK);
|
|
334
|
-
} while (bits & 7);
|
|
335
|
-
err = deflate(stream,Z_BLOCK);
|
|
336
|
-
_check_zlib_err(Z_OK);
|
|
337
|
-
}
|
|
338
|
-
}else{
|
|
339
|
-
err = deflate(stream,Z_FINISH);
|
|
340
|
-
_check_zlib_err(Z_STREAM_END);
|
|
341
|
-
err=Z_OK;
|
|
342
|
-
}
|
|
343
|
-
*destLen = stream->total_out;
|
|
289
|
+
*destLen = stream.total_out;
|
|
290
|
+
err = deflateEnd(&stream);
|
|
344
291
|
return err;
|
|
345
|
-
_errorReturn:
|
|
346
|
-
return err == Z_OK ? Z_BUF_ERROR : err;
|
|
347
|
-
#undef _check_zlib_err
|
|
348
292
|
}
|
|
349
293
|
static
|
|
350
294
|
size_t _pzlib_compressBlock(hdiff_TParallelCompress* pc,hdiff_compressBlockHandle blockCompressor,
|
|
351
|
-
hpatch_StreamPos_t blockIndex,
|
|
352
|
-
const unsigned char* block_data,const unsigned char*
|
|
295
|
+
hpatch_StreamPos_t blockIndex,unsigned char* out_code,unsigned char* out_codeEnd,
|
|
296
|
+
const unsigned char* block_data,const unsigned char* block_dataEnd){
|
|
353
297
|
const TCompressPlugin_pzlib* plugin=(const TCompressPlugin_pzlib*)pc->import;
|
|
354
|
-
|
|
298
|
+
hpatch_BOOL isAdding=(blockIndex==0)&&(plugin->base.isNeedSaveWindowBits);
|
|
355
299
|
if (isAdding){
|
|
356
300
|
if (out_code>=out_codeEnd) return 0;//error;
|
|
357
301
|
out_code[0]=plugin->base.windowBits;
|
|
358
302
|
++out_code;
|
|
359
303
|
}
|
|
360
304
|
uLongf codeLen=(uLongf)(out_codeEnd-out_code);
|
|
361
|
-
if (Z_OK!=_pzlib_compress2(out_code,&codeLen,block_data,
|
|
362
|
-
|
|
305
|
+
if (Z_OK!=_pzlib_compress2(out_code,&codeLen,block_data,(uLong)(block_dataEnd-block_data),
|
|
306
|
+
plugin->base.compress_level,plugin->base.mem_level,plugin->base.windowBits))
|
|
363
307
|
return 0; //error
|
|
364
308
|
return codeLen+(isAdding?1:0);
|
|
365
309
|
}
|
|
@@ -367,185 +311,26 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
367
311
|
const hpatch_TStreamOutput* out_code,
|
|
368
312
|
const hpatch_TStreamInput* in_data){
|
|
369
313
|
TCompressPlugin_pzlib* plugin=(TCompressPlugin_pzlib*)compressPlugin;
|
|
370
|
-
const size_t blockSize=
|
|
314
|
+
const size_t blockSize=(plugin->base.compress_level>1)?
|
|
315
|
+
1024*128*(plugin->base.compress_level-1):1024*128;
|
|
371
316
|
if ((plugin->thread_num<=1)||(plugin->base.compress_level==0)
|
|
372
317
|
||(in_data->streamSize<blockSize*2)){ //same as "zlib"
|
|
373
318
|
return _zlib_compress(compressPlugin,out_code,in_data);
|
|
374
319
|
}else{
|
|
375
|
-
int dictBits=plugin->base.windowBits;
|
|
376
|
-
if (dictBits<0) dictBits=-dictBits;
|
|
377
|
-
if (dictBits>15) dictBits-=16;
|
|
378
|
-
if (dictBits<9) dictBits=9;
|
|
379
|
-
else if (dictBits>15) dictBits=15;
|
|
380
320
|
plugin->pc.import=plugin;
|
|
381
|
-
return parallel_compress_blocks(&plugin->pc,plugin->thread_num,
|
|
321
|
+
return parallel_compress_blocks(&plugin->pc,plugin->thread_num,blockSize,out_code,in_data);
|
|
382
322
|
}
|
|
383
323
|
}
|
|
384
324
|
|
|
325
|
+
_def_fun_compressType(_pzlib_compressType,"pzlib");
|
|
385
326
|
static const TCompressPlugin_pzlib pzlibCompressPlugin={
|
|
386
|
-
{ {
|
|
327
|
+
{ {_pzlib_compressType,_default_maxCompressedSize,_pzlib_setThreadNum,_pzlib_compress},
|
|
387
328
|
6,8,-MAX_WBITS,hpatch_TRUE,Z_DEFAULT_STRATEGY},
|
|
388
329
|
kDefaultCompressThreadNumber ,{0,_default_maxCompressedSize,_pzlib_openBlockCompressor,
|
|
389
330
|
_pzlib_closeBlockCompressor,_pzlib_compressBlock} };
|
|
390
331
|
# endif // _IS_USED_MULTITHREAD
|
|
391
332
|
#endif//_CompressPlugin_zlib
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
#ifdef _CompressPlugin_ldef
|
|
395
|
-
#if (_IsNeedIncludeDefaultCompressHead)
|
|
396
|
-
# include "libdeflate.h" // "libdeflate/libdeflate.h" https://github.com/sisong/libdeflate/tree/stream-mt based on https://github.com/ebiggers/libdeflate
|
|
397
|
-
#endif
|
|
398
|
-
static const signed char _ldef_kWindowBits=-15; //always as zlib's windowBits -15
|
|
399
|
-
static const size_t _ldef_kDictSize=(1<<15);
|
|
400
|
-
static const size_t _ldef_kMax_in_border_nbytes=258;//deflate max match len
|
|
401
|
-
static size_t _ldef_getBestWorkStepSize(hpatch_StreamPos_t data_size,size_t compress_level,size_t thread_num){
|
|
402
|
-
const size_t _kMinBaseStep=600000;
|
|
403
|
-
size_t base_step_size=1024*1024*2;
|
|
404
|
-
hpatch_StreamPos_t work_count=(data_size+base_step_size-1)/base_step_size;
|
|
405
|
-
if (work_count>=thread_num) return base_step_size;
|
|
406
|
-
size_t step_size=(size_t)((data_size+thread_num-1)/thread_num);
|
|
407
|
-
const size_t minStep=_kMinBaseStep;
|
|
408
|
-
step_size=(step_size>minStep)?step_size:minStep;
|
|
409
|
-
return step_size;
|
|
410
|
-
}
|
|
411
|
-
typedef struct{
|
|
412
|
-
hdiff_TCompress base;
|
|
413
|
-
int compress_level; //0..12
|
|
414
|
-
hpatch_BOOL isNeedSaveWindowBits;
|
|
415
|
-
} TCompressPlugin_ldef;
|
|
416
|
-
|
|
417
|
-
static hpatch_StreamPos_t _ldef_compress(const hdiff_TCompress* compressPlugin,
|
|
418
|
-
const hpatch_TStreamOutput* out_code,
|
|
419
|
-
const hpatch_TStreamInput* in_data){
|
|
420
|
-
const TCompressPlugin_ldef* plugin=(const TCompressPlugin_ldef*)compressPlugin;
|
|
421
|
-
hpatch_StreamPos_t result=0; //writedPos
|
|
422
|
-
hpatch_StreamPos_t readFromPos=0;
|
|
423
|
-
const char* errAt="";
|
|
424
|
-
int outStream_isCanceled=0;
|
|
425
|
-
unsigned char* data_buf=0;
|
|
426
|
-
unsigned char* code_buf=0;
|
|
427
|
-
struct libdeflate_compressor* c=0;
|
|
428
|
-
size_t in_border_nbytes=0;
|
|
429
|
-
const size_t in_step_size=_ldef_getBestWorkStepSize(in_data->streamSize,plugin->compress_level,1);
|
|
430
|
-
const size_t _in_buf_size=_ldef_kDictSize+in_step_size+_ldef_kMax_in_border_nbytes;
|
|
431
|
-
const size_t block_bound=libdeflate_deflate_compress_bound_block(in_step_size);
|
|
432
|
-
|
|
433
|
-
data_buf=(unsigned char*)malloc(_in_buf_size+block_bound);
|
|
434
|
-
if (!data_buf) _compress_error_return("memory alloc");
|
|
435
|
-
code_buf=data_buf+_in_buf_size;
|
|
436
|
-
|
|
437
|
-
c=libdeflate_alloc_compressor(plugin->compress_level);
|
|
438
|
-
if (!c) _compress_error_return("libdeflate_alloc_compressor()");
|
|
439
|
-
|
|
440
|
-
if (plugin->isNeedSaveWindowBits){//save deflate windowBits
|
|
441
|
-
const unsigned char* pchar=(const unsigned char*)&_ldef_kWindowBits;
|
|
442
|
-
if (!out_code->write(out_code,0,pchar,pchar+1)) _compress_error_return("out_code->write()");
|
|
443
|
-
++result;
|
|
444
|
-
}
|
|
445
|
-
while (readFromPos<in_data->streamSize){
|
|
446
|
-
const size_t curDictSize=(readFromPos>0)?_ldef_kDictSize:0;
|
|
447
|
-
size_t readLen=in_step_size;
|
|
448
|
-
size_t codeLen;
|
|
449
|
-
if (readLen>(hpatch_StreamPos_t)(in_data->streamSize-readFromPos))
|
|
450
|
-
readLen=(size_t)(in_data->streamSize-readFromPos);
|
|
451
|
-
{
|
|
452
|
-
unsigned char* dst_buf=data_buf+curDictSize+in_border_nbytes;
|
|
453
|
-
size_t cur_in_border_nbytes=_ldef_kMax_in_border_nbytes;
|
|
454
|
-
if (readLen+cur_in_border_nbytes>(hpatch_StreamPos_t)(in_data->streamSize-readFromPos))
|
|
455
|
-
cur_in_border_nbytes=(size_t)(in_data->streamSize-readFromPos-readLen);
|
|
456
|
-
if (!in_data->read(in_data,readFromPos+in_border_nbytes,dst_buf,
|
|
457
|
-
dst_buf+readLen+cur_in_border_nbytes-in_border_nbytes))
|
|
458
|
-
_compress_error_return("in_data->read()");
|
|
459
|
-
in_border_nbytes=cur_in_border_nbytes;
|
|
460
|
-
}
|
|
461
|
-
readFromPos+=readLen;
|
|
462
|
-
|
|
463
|
-
codeLen=libdeflate_deflate_compress_block_continue(c,data_buf,curDictSize,readLen,in_border_nbytes,
|
|
464
|
-
(readFromPos==in_data->streamSize),code_buf,block_bound,hpatch_FALSE);
|
|
465
|
-
|
|
466
|
-
if (codeLen>0){
|
|
467
|
-
_stream_out_code_write(out_code,outStream_isCanceled,result,code_buf,codeLen);
|
|
468
|
-
}else
|
|
469
|
-
_compress_error_return("libdeflate_deflate_compress_block_continue()");
|
|
470
|
-
if (readFromPos<in_data->streamSize){
|
|
471
|
-
memmove(data_buf,data_buf+readLen+curDictSize-_ldef_kDictSize,_ldef_kDictSize+in_border_nbytes);
|
|
472
|
-
}
|
|
473
|
-
}
|
|
474
|
-
clear:
|
|
475
|
-
if (c) libdeflate_free_compressor(c);
|
|
476
|
-
_check_compress_result(result,outStream_isCanceled,"_ldef_compress()",errAt);
|
|
477
|
-
if (data_buf) free(data_buf);
|
|
478
|
-
return result;
|
|
479
|
-
}
|
|
480
|
-
_def_fun_compressType(_ldef_compressType,"zlib");
|
|
481
|
-
_def_fun_compressType(_ldef_compressTypeForDisplay,"ldef (zlib compatible)");
|
|
482
|
-
static const TCompressPlugin_ldef ldefCompressPlugin={
|
|
483
|
-
{_ldef_compressType,_default_maxCompressedSize,_default_setParallelThreadNumber,
|
|
484
|
-
_ldef_compress,_ldef_compressTypeForDisplay}, 12,hpatch_TRUE};
|
|
485
|
-
|
|
486
|
-
# if (_IS_USED_MULTITHREAD)
|
|
487
|
-
//pldef
|
|
488
|
-
typedef struct {
|
|
489
|
-
TCompressPlugin_ldef base;
|
|
490
|
-
int thread_num; // 1..
|
|
491
|
-
hdiff_TParallelCompress pc;
|
|
492
|
-
} TCompressPlugin_pldef;
|
|
493
|
-
static int _pldef_setThreadNum(hdiff_TCompress* compressPlugin,int threadNum){
|
|
494
|
-
TCompressPlugin_pldef* plugin=(TCompressPlugin_pldef*)compressPlugin;
|
|
495
|
-
plugin->thread_num=threadNum;
|
|
496
|
-
return threadNum;
|
|
497
|
-
}
|
|
498
|
-
static hdiff_compressBlockHandle _pldef_openBlockCompressor(hdiff_TParallelCompress* pc){
|
|
499
|
-
const TCompressPlugin_pldef* plugin=(const TCompressPlugin_pldef*)pc->import;
|
|
500
|
-
return libdeflate_alloc_compressor(plugin->base.compress_level);
|
|
501
|
-
}
|
|
502
|
-
static void _pldef_closeBlockCompressor(hdiff_TParallelCompress* pc,
|
|
503
|
-
hdiff_compressBlockHandle blockCompressor){
|
|
504
|
-
libdeflate_free_compressor((struct libdeflate_compressor*)blockCompressor);
|
|
505
|
-
}
|
|
506
|
-
static
|
|
507
|
-
size_t _pldef_compressBlock(hdiff_TParallelCompress* pc,hdiff_compressBlockHandle blockCompressor,
|
|
508
|
-
hpatch_StreamPos_t blockIndex,hpatch_StreamPos_t blockCount,unsigned char* out_code,unsigned char* out_codeEnd,
|
|
509
|
-
const unsigned char* block_data,const unsigned char* block_dictEnd,const unsigned char* block_dataEnd){
|
|
510
|
-
const TCompressPlugin_pldef* plugin=(const TCompressPlugin_pldef*)pc->import;
|
|
511
|
-
struct libdeflate_compressor* c=(struct libdeflate_compressor*)blockCompressor;
|
|
512
|
-
const hpatch_BOOL isAdding=(blockIndex==0)&&plugin->base.isNeedSaveWindowBits;
|
|
513
|
-
if (isAdding){
|
|
514
|
-
if (out_code>=out_codeEnd) return 0;//error;
|
|
515
|
-
out_code[0]=_ldef_kWindowBits;
|
|
516
|
-
++out_code;
|
|
517
|
-
}
|
|
518
|
-
|
|
519
|
-
size_t codeLen=libdeflate_deflate_compress_block(c,block_data,block_dictEnd-block_data,block_dataEnd-block_dictEnd,
|
|
520
|
-
blockIndex+1==blockCount,out_code,out_codeEnd-out_code,1);
|
|
521
|
-
if (codeLen==0)
|
|
522
|
-
return 0; //error
|
|
523
|
-
return codeLen+(isAdding?1:0);
|
|
524
|
-
}
|
|
525
|
-
static hpatch_StreamPos_t _pldef_compress(const hdiff_TCompress* compressPlugin,
|
|
526
|
-
const hpatch_TStreamOutput* out_code,
|
|
527
|
-
const hpatch_TStreamInput* in_data){
|
|
528
|
-
TCompressPlugin_pldef* plugin=(TCompressPlugin_pldef*)compressPlugin;
|
|
529
|
-
const size_t blockSize=_ldef_getBestWorkStepSize(in_data->streamSize,plugin->base.compress_level,plugin->thread_num);
|
|
530
|
-
if ((plugin->thread_num<=1)||(plugin->base.compress_level==0)
|
|
531
|
-
||(in_data->streamSize<blockSize*2)){ //same as "zlib"
|
|
532
|
-
return _ldef_compress(compressPlugin,out_code,in_data);
|
|
533
|
-
}else{
|
|
534
|
-
plugin->pc.import=plugin;
|
|
535
|
-
return parallel_compress_blocks(&plugin->pc,plugin->thread_num,_ldef_kDictSize,blockSize,out_code,in_data);
|
|
536
|
-
}
|
|
537
|
-
}
|
|
538
333
|
|
|
539
|
-
|
|
540
|
-
static const TCompressPlugin_pldef pldefCompressPlugin={
|
|
541
|
-
{ {_ldef_compressType,_default_maxCompressedSize,_pldef_setThreadNum,
|
|
542
|
-
_pldef_compress,_ldef_compressTypeForDisplay}, 9,hpatch_TRUE},
|
|
543
|
-
kDefaultCompressThreadNumber ,{0,_default_maxCompressedSize,_pldef_openBlockCompressor,
|
|
544
|
-
_pldef_closeBlockCompressor,_pldef_compressBlock} };
|
|
545
|
-
# endif // _IS_USED_MULTITHREAD
|
|
546
|
-
#endif//_CompressPlugin_ldef
|
|
547
|
-
|
|
548
|
-
|
|
549
334
|
#ifdef _CompressPlugin_bz2
|
|
550
335
|
#if (_IsNeedIncludeDefaultCompressHead)
|
|
551
336
|
# include "bzlib.h" // http://www.bzip.org/ https://github.com/sisong/bzip2
|
|
@@ -643,8 +428,8 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
643
428
|
}
|
|
644
429
|
static
|
|
645
430
|
size_t _pbz2_compressBlock(hdiff_TParallelCompress* pc,hdiff_compressBlockHandle blockCompressor,
|
|
646
|
-
hpatch_StreamPos_t blockIndex,
|
|
647
|
-
const unsigned char* block_data,const unsigned char*
|
|
431
|
+
hpatch_StreamPos_t blockIndex,unsigned char* out_code,unsigned char* out_codeEnd,
|
|
432
|
+
const unsigned char* block_data,const unsigned char* block_dataEnd){
|
|
648
433
|
const TCompressPlugin_pbz2* plugin=(const TCompressPlugin_pbz2*)pc->import;
|
|
649
434
|
unsigned int codeLen=(unsigned int)(out_codeEnd-out_code);
|
|
650
435
|
if (BZ_OK!=BZ2_bzBuffToBuffCompress((char*)out_code,&codeLen,(char*)block_data,
|
|
@@ -662,7 +447,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
662
447
|
return _bz2_compress(compressPlugin,out_code,in_data);
|
|
663
448
|
}else{
|
|
664
449
|
plugin->pc.import=plugin;
|
|
665
|
-
return parallel_compress_blocks(&plugin->pc,plugin->thread_num,
|
|
450
|
+
return parallel_compress_blocks(&plugin->pc,plugin->thread_num,blockSize,out_code,in_data);
|
|
666
451
|
}
|
|
667
452
|
}
|
|
668
453
|
|
|
@@ -675,7 +460,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
675
460
|
#endif//_CompressPlugin_bz2
|
|
676
461
|
|
|
677
462
|
|
|
678
|
-
#if (defined _CompressPlugin_lzma)||(defined _CompressPlugin_lzma2)
|
|
463
|
+
#if (defined _CompressPlugin_lzma)||(defined _CompressPlugin_lzma2)
|
|
679
464
|
#if (_IsNeedIncludeDefaultCompressHead)
|
|
680
465
|
# include "LzmaEnc.h" // "lzma/C/LzmaEnc.h" https://github.com/sisong/lzma
|
|
681
466
|
# ifdef _CompressPlugin_lzma2
|
|
@@ -735,7 +520,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
735
520
|
typedef struct{
|
|
736
521
|
hdiff_TCompress base;
|
|
737
522
|
int compress_level; //0..9
|
|
738
|
-
UInt32 dict_size; //patch decompress need 4
|
|
523
|
+
UInt32 dict_size; //patch decompress need 4*lzma_dictSize memroy
|
|
739
524
|
int thread_num; //1..2
|
|
740
525
|
} TCompressPlugin_lzma;
|
|
741
526
|
static int _lzma_setThreadNumber(hdiff_TCompress* compressPlugin,int threadNum){
|
|
@@ -772,7 +557,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
772
557
|
LzmaEncProps_Normalize(&props);
|
|
773
558
|
if (SZ_OK!=LzmaEnc_SetProps(s,&props)) _compress_error_return("LzmaEnc_SetProps()");
|
|
774
559
|
# if (IS_NOTICE_compress_canceled)
|
|
775
|
-
printf("
|
|
560
|
+
printf(" (used one lzma dictSize: %" PRIu64 " (input data: %" PRIu64 "))\n",
|
|
776
561
|
(hpatch_StreamPos_t)props.dictSize,in_data->streamSize);
|
|
777
562
|
# endif
|
|
778
563
|
|
|
@@ -798,7 +583,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
798
583
|
}
|
|
799
584
|
clear:
|
|
800
585
|
#if (!IS_REUSE_compress_handle)
|
|
801
|
-
if (s)
|
|
586
|
+
if (s) LzmaEnc_Destroy(s,&__lzma_enc_alloc,&__lzma_enc_alloc);
|
|
802
587
|
#endif
|
|
803
588
|
_check_compress_result(result,outStream.isCanceled,"_lzma_compress()",errAt);
|
|
804
589
|
return result;
|
|
@@ -811,17 +596,17 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
811
596
|
|
|
812
597
|
#ifdef _CompressPlugin_lzma2
|
|
813
598
|
#if (_IsNeedIncludeDefaultCompressHead)
|
|
814
|
-
# include "MtCoder.h" // "lzma/C/MtCoder.h" for MTCODER__THREADS_MAX
|
|
599
|
+
# include "MtCoder.h" // // "lzma/C/MtCoder.h" for MTCODER__THREADS_MAX
|
|
815
600
|
#endif
|
|
816
601
|
struct TCompressPlugin_lzma2{
|
|
817
602
|
hdiff_TCompress base;
|
|
818
603
|
int compress_level; //0..9
|
|
819
|
-
UInt32 dict_size; //patch decompress need 4
|
|
604
|
+
UInt32 dict_size; //patch decompress need 4*lzma_dictSize memroy
|
|
820
605
|
int thread_num; //1..(64?)
|
|
821
606
|
};
|
|
822
607
|
static int _lzma2_setThreadNumber(hdiff_TCompress* compressPlugin,int threadNum){
|
|
823
608
|
TCompressPlugin_lzma2* plugin=(TCompressPlugin_lzma2*)compressPlugin;
|
|
824
|
-
if (threadNum>
|
|
609
|
+
if (threadNum>MTCODER__THREADS_MAX) threadNum=MTCODER__THREADS_MAX;
|
|
825
610
|
plugin->thread_num=threadNum;
|
|
826
611
|
return threadNum;
|
|
827
612
|
}
|
|
@@ -848,12 +633,12 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
848
633
|
props.lzmaProps.level=plugin->compress_level;
|
|
849
634
|
props.lzmaProps.dictSize=dictSize;
|
|
850
635
|
props.lzmaProps.reduceSize=in_data->streamSize;
|
|
851
|
-
props.blockSize=
|
|
636
|
+
props.blockSize=LZMA2_ENC_PROPS__BLOCK_SIZE__AUTO;
|
|
852
637
|
props.numTotalThreads=plugin->thread_num;
|
|
853
638
|
Lzma2EncProps_Normalize(&props);
|
|
854
639
|
if (SZ_OK!=Lzma2Enc_SetProps(s,&props)) _compress_error_return("Lzma2Enc_SetProps()");
|
|
855
640
|
# if (IS_NOTICE_compress_canceled)
|
|
856
|
-
printf("
|
|
641
|
+
printf(" (used one lzma2 dictSize: %" PRIu64 " (input data: %" PRIu64 "))\n",
|
|
857
642
|
(hpatch_StreamPos_t)props.lzmaProps.dictSize,in_data->streamSize);
|
|
858
643
|
# endif
|
|
859
644
|
|
|
@@ -877,7 +662,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
877
662
|
}
|
|
878
663
|
clear:
|
|
879
664
|
#if (!IS_REUSE_compress_handle)
|
|
880
|
-
if (s)
|
|
665
|
+
if (s) Lzma2Enc_Destroy(s);
|
|
881
666
|
#endif
|
|
882
667
|
_check_compress_result(result,outStream.isCanceled,"_lzma2_compress()",errAt);
|
|
883
668
|
return result;
|
|
@@ -888,126 +673,6 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
888
673
|
7,(1<<23),kDefaultCompressThreadNumber};
|
|
889
674
|
#endif//_CompressPlugin_lzma2
|
|
890
675
|
|
|
891
|
-
#ifdef _CompressPlugin_7zXZ
|
|
892
|
-
#if (_IsNeedIncludeDefaultCompressHead)
|
|
893
|
-
# include "XzEnc.h" // "lzma/C/XzEnc.h" https://github.com/sisong/lzma
|
|
894
|
-
# include "MtCoder.h" // "lzma/C/MtCoder.h" for MTCODER__THREADS_MAX
|
|
895
|
-
# include "7zCrc.h" // CrcGenerateTable()
|
|
896
|
-
#endif
|
|
897
|
-
|
|
898
|
-
#ifndef _init_CompressPlugin_7zXZ_DEF
|
|
899
|
-
# define _init_CompressPlugin_7zXZ_DEF
|
|
900
|
-
static int _init_CompressPlugin_7zXZ(){
|
|
901
|
-
static hpatch_BOOL _isInit=hpatch_FALSE;
|
|
902
|
-
if (!_isInit){
|
|
903
|
-
CrcGenerateTable();
|
|
904
|
-
_isInit=hpatch_TRUE;
|
|
905
|
-
}
|
|
906
|
-
return 0;
|
|
907
|
-
}
|
|
908
|
-
#endif
|
|
909
|
-
|
|
910
|
-
typedef struct{
|
|
911
|
-
hdiff_TCompress base;
|
|
912
|
-
int compress_level; //0..9
|
|
913
|
-
UInt32 dict_size; //patch decompress need 3?*lzma_dictSize memory
|
|
914
|
-
int thread_num; //1..(64?)
|
|
915
|
-
} TCompressPlugin_7zXZ;
|
|
916
|
-
static int _7zXZ_setThreadNumber(hdiff_TCompress* compressPlugin,int threadNum){
|
|
917
|
-
TCompressPlugin_lzma2* plugin=(TCompressPlugin_lzma2*)compressPlugin;
|
|
918
|
-
if (threadNum>MTCODER_THREADS_MAX) threadNum=MTCODER_THREADS_MAX;
|
|
919
|
-
plugin->thread_num=threadNum;
|
|
920
|
-
return threadNum;
|
|
921
|
-
}
|
|
922
|
-
|
|
923
|
-
typedef void* _7zXZ_compressHandle;
|
|
924
|
-
static _7zXZ_compressHandle _7zXZ_compress_open(const hdiff_TCompress* compressPlugin){
|
|
925
|
-
const TCompressPlugin_7zXZ* plugin=(const TCompressPlugin_7zXZ*)compressPlugin;
|
|
926
|
-
_7zXZ_compressHandle result=0;
|
|
927
|
-
const char* errAt="";
|
|
928
|
-
#if (IS_REUSE_compress_handle)
|
|
929
|
-
static CXzEncHandle s=0;
|
|
930
|
-
#else
|
|
931
|
-
CXzEncHandle s=0;
|
|
932
|
-
#endif
|
|
933
|
-
CXzProps xzprops;
|
|
934
|
-
hpatch_uint32_t dictSize=plugin->dict_size;
|
|
935
|
-
if (!s) s=XzEnc_Create(&__lzma_enc_alloc,&__lzma_enc_alloc);
|
|
936
|
-
if (!s) _compress_error_return("XzEnc_Create()");
|
|
937
|
-
XzProps_Init(&xzprops);
|
|
938
|
-
xzprops.lzma2Props.lzmaProps.level=plugin->compress_level;
|
|
939
|
-
xzprops.lzma2Props.lzmaProps.dictSize=dictSize;
|
|
940
|
-
xzprops.lzma2Props.numTotalThreads=plugin->thread_num;
|
|
941
|
-
Lzma2EncProps_Normalize(&xzprops.lzma2Props);
|
|
942
|
-
xzprops.numTotalThreads=plugin->thread_num;
|
|
943
|
-
xzprops.checkId=XZ_CHECK_NO;
|
|
944
|
-
if (SZ_OK!=XzEnc_SetProps(s,&xzprops)) _compress_error_return("XzEnc_SetProps()");
|
|
945
|
-
return s;
|
|
946
|
-
clear:
|
|
947
|
-
#if (!IS_REUSE_compress_handle)
|
|
948
|
-
if (s) { XzEnc_Destroy(s); s=0; }
|
|
949
|
-
#endif
|
|
950
|
-
return result;
|
|
951
|
-
}
|
|
952
|
-
static hpatch_BOOL _7zXZ_compress_close(const hdiff_TCompress* compressPlugin,
|
|
953
|
-
_7zXZ_compressHandle compressHandle){
|
|
954
|
-
#if (!IS_REUSE_compress_handle)
|
|
955
|
-
CXzEncHandle s=(CXzEncHandle)compressHandle;
|
|
956
|
-
if (s) { XzEnc_Destroy(s); s=0; }
|
|
957
|
-
#endif
|
|
958
|
-
return hpatch_TRUE;
|
|
959
|
-
}
|
|
960
|
-
|
|
961
|
-
static hpatch_StreamPos_t _7zXZ_compress_encode(_7zXZ_compressHandle compressHandle,
|
|
962
|
-
const hpatch_TStreamOutput* out_code,
|
|
963
|
-
const hpatch_TStreamInput* in_data,
|
|
964
|
-
hpatch_BOOL isWriteHead,hpatch_BOOL isWriteEnd){
|
|
965
|
-
struct __lzma_SeqOutStream_t outStream={{__lzma_SeqOutStream_Write},out_code,0,0};
|
|
966
|
-
struct __lzma_SeqInStream_t inStream={{__lzma_SeqInStream_Read},in_data,0};
|
|
967
|
-
hpatch_StreamPos_t result=0;
|
|
968
|
-
const char* errAt="";
|
|
969
|
-
CXzEncHandle s=(CXzEncHandle)compressHandle;
|
|
970
|
-
SRes ret;
|
|
971
|
-
XzEnc_SetDataSize(s,in_data->streamSize);
|
|
972
|
-
|
|
973
|
-
ret=XzEnc_Encode_Part(s,&outStream.base,&inStream.base,0,isWriteHead,isWriteEnd);
|
|
974
|
-
if (SZ_OK==ret){
|
|
975
|
-
result=outStream.writeToPos;
|
|
976
|
-
}else{//fail
|
|
977
|
-
if (ret==SZ_ERROR_READ)
|
|
978
|
-
_compress_error_return("in_data->read()");
|
|
979
|
-
else if (ret==SZ_ERROR_WRITE)
|
|
980
|
-
_compress_error_return("out_code->write()");
|
|
981
|
-
else
|
|
982
|
-
_compress_error_return("XzEnc_Encode_Part()");
|
|
983
|
-
}
|
|
984
|
-
clear:
|
|
985
|
-
_check_compress_result(result,outStream.isCanceled,"_7zXZ_compress_encode()",errAt);
|
|
986
|
-
return result;
|
|
987
|
-
}
|
|
988
|
-
|
|
989
|
-
static hpatch_StreamPos_t _7zXZ_compress(const hdiff_TCompress* compressPlugin,
|
|
990
|
-
const hpatch_TStreamOutput* out_code,
|
|
991
|
-
const hpatch_TStreamInput* in_data){
|
|
992
|
-
const TCompressPlugin_7zXZ* plugin=(const TCompressPlugin_7zXZ*)compressPlugin;
|
|
993
|
-
hpatch_StreamPos_t result=0;
|
|
994
|
-
const char* errAt="";
|
|
995
|
-
_7zXZ_compressHandle s=_7zXZ_compress_open(compressPlugin);
|
|
996
|
-
if (!s) _compress_error_return("_7zXZ_compress_open()");
|
|
997
|
-
result=_7zXZ_compress_encode(s,out_code,in_data,hpatch_TRUE,hpatch_TRUE);
|
|
998
|
-
if (result==0)
|
|
999
|
-
_compress_error_return("_7zXZ_compress_encode()");
|
|
1000
|
-
clear:
|
|
1001
|
-
if (s) { _7zXZ_compress_close(compressPlugin,s); s=0; }
|
|
1002
|
-
return result;
|
|
1003
|
-
}
|
|
1004
|
-
_def_fun_compressType(_7zXZ_compressType,"7zXZ");
|
|
1005
|
-
static const TCompressPlugin_7zXZ _7zXZCompressPlugin={
|
|
1006
|
-
{_7zXZ_compressType,_default_maxCompressedSize,_7zXZ_setThreadNumber,_7zXZ_compress},
|
|
1007
|
-
7,(1<<23),kDefaultCompressThreadNumber};
|
|
1008
|
-
|
|
1009
|
-
#endif //_CompressPlugin_7zXZ
|
|
1010
|
-
|
|
1011
676
|
|
|
1012
677
|
#if (defined(_CompressPlugin_lz4) || defined(_CompressPlugin_lz4hc))
|
|
1013
678
|
#if (_IsNeedIncludeDefaultCompressHead)
|
|
@@ -1043,7 +708,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1043
708
|
LZ4_stream_t* s=0;
|
|
1044
709
|
hpatch_StreamPos_t readFromPos=0;
|
|
1045
710
|
int outStream_isCanceled=0;
|
|
1046
|
-
int kLz4CompressBufSize =1024*510; //patch decompress need 4*2*0.5MB
|
|
711
|
+
int kLz4CompressBufSize =1024*510; //patch decompress need 4*2*0.5MB memroy
|
|
1047
712
|
int code_buf_size;
|
|
1048
713
|
if ((size_t)kLz4CompressBufSize>in_data->streamSize)
|
|
1049
714
|
kLz4CompressBufSize=(int)in_data->streamSize;
|
|
@@ -1101,7 +766,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1101
766
|
LZ4_streamHC_t* s=0;
|
|
1102
767
|
hpatch_StreamPos_t readFromPos=0;
|
|
1103
768
|
int outStream_isCanceled=0;
|
|
1104
|
-
int kLz4CompressBufSize =1024*510; //patch decompress need 4*2*0.5MB
|
|
769
|
+
int kLz4CompressBufSize =1024*510; //patch decompress need 4*2*0.5MB memroy
|
|
1105
770
|
int code_buf_size;
|
|
1106
771
|
if ((size_t)kLz4CompressBufSize>in_data->streamSize)
|
|
1107
772
|
kLz4CompressBufSize=(int)in_data->streamSize;
|
|
@@ -1159,7 +824,7 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1159
824
|
|
|
1160
825
|
#ifdef _CompressPlugin_zstd
|
|
1161
826
|
#if (_IsNeedIncludeDefaultCompressHead)
|
|
1162
|
-
# include "zstd.h" // "zstd/lib/zstd.h" https://github.com/
|
|
827
|
+
# include "zstd.h" // "zstd/lib/zstd.h" https://github.com/facebook/zstd
|
|
1163
828
|
#endif
|
|
1164
829
|
struct TCompressPlugin_zstd{
|
|
1165
830
|
hdiff_TCompress base;
|
|
@@ -1184,9 +849,9 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1184
849
|
ZSTD_inBuffer s_input;
|
|
1185
850
|
ZSTD_outBuffer s_output;
|
|
1186
851
|
#if (IS_REUSE_compress_handle)
|
|
1187
|
-
static
|
|
852
|
+
static ZSTD_CStream* s=0;
|
|
1188
853
|
#else
|
|
1189
|
-
|
|
854
|
+
ZSTD_CStream* s=0;
|
|
1190
855
|
#endif
|
|
1191
856
|
hpatch_StreamPos_t readFromPos=0;
|
|
1192
857
|
int outStream_isCanceled=0;
|
|
@@ -1200,62 +865,55 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1200
865
|
s_input.src=_temp_buf;
|
|
1201
866
|
s_output.dst=_temp_buf+s_input.size;
|
|
1202
867
|
|
|
1203
|
-
if (!s) s=
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
ret
|
|
1207
|
-
|
|
1208
|
-
ZSTD_CCtx_setPledgedSrcSize(s,in_data->streamSize);
|
|
868
|
+
if (!s) s=ZSTD_createCStream();
|
|
869
|
+
if (!s) _compress_error_return("ZSTD_createCStream()");
|
|
870
|
+
ret=ZSTD_initCStream(s,plugin->compress_level);
|
|
871
|
+
if (ZSTD_isError(ret)) _compress_error_return("ZSTD_initCStream()");
|
|
872
|
+
|
|
1209
873
|
#define _ZSTD_WINDOWLOG_MIN 10
|
|
1210
874
|
dict_bits=plugin->dict_bits;
|
|
1211
|
-
|
|
875
|
+
while (((((hpatch_StreamPos_t)1)<<(dict_bits-1)) >= in_data->streamSize)
|
|
1212
876
|
&&((dict_bits-1)>=_ZSTD_WINDOWLOG_MIN)) {
|
|
1213
877
|
--dict_bits;
|
|
1214
878
|
}
|
|
1215
|
-
|
|
1216
|
-
printf(" (used one zstd dictSize: %" PRIu64 " (input data: %" PRIu64 "))\n",
|
|
1217
|
-
((hpatch_StreamPos_t)1)<<dict_bits,in_data->streamSize);
|
|
1218
|
-
# endif
|
|
1219
|
-
ret=ZSTD_CCtx_setParameter(s,ZSTD_c_windowLog,dict_bits);
|
|
879
|
+
ret=ZSTD_CCtx_setParameter(s, ZSTD_c_windowLog,plugin->dict_bits);
|
|
1220
880
|
if (ZSTD_isError(ret)) _compress_error_return("ZSTD_CCtx_setParameter(,ZSTD_c_windowLog)");
|
|
1221
881
|
if (plugin->thread_num>1){
|
|
1222
882
|
ret=ZSTD_CCtx_setParameter(s, ZSTD_c_nbWorkers,plugin->thread_num);
|
|
1223
883
|
//if (ZSTD_isError(ret)) printf(" (NOTICE: zstd unsupport multi-threading, warning.)\n");
|
|
1224
884
|
}
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
885
|
+
|
|
886
|
+
while (readFromPos<in_data->streamSize) {
|
|
887
|
+
s_input.pos=0;
|
|
888
|
+
if (s_input.size>(in_data->streamSize-readFromPos))
|
|
889
|
+
s_input.size=(size_t)(in_data->streamSize-readFromPos);
|
|
890
|
+
if (!in_data->read(in_data,readFromPos,(unsigned char*)s_input.src,
|
|
891
|
+
(unsigned char*)s_input.src+s_input.size))
|
|
892
|
+
_compress_error_return("in_data->read()");
|
|
893
|
+
readFromPos+=s_input.size;
|
|
894
|
+
while (s_input.pos<s_input.size) {
|
|
895
|
+
s_output.pos=0;
|
|
896
|
+
ret=ZSTD_compressStream(s,&s_output,&s_input);
|
|
897
|
+
if (ZSTD_isError(ret)) _compress_error_return("ZSTD_compressStream()");
|
|
898
|
+
if (s_output.pos>0){
|
|
899
|
+
_stream_out_code_write(out_code,outStream_isCanceled,result,
|
|
900
|
+
(const unsigned char*)s_output.dst,s_output.pos);
|
|
901
|
+
}
|
|
1235
902
|
}
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
if (ZSTD_isError(ret)) _compress_error_return("ZSTD_compressStream2()");
|
|
1244
|
-
if (s_output.pos>0){
|
|
1245
|
-
_stream_out_code_write(out_code,outStream_isCanceled,result,
|
|
1246
|
-
(const unsigned char*)s_output.dst,s_output.pos);
|
|
1247
|
-
}
|
|
1248
|
-
finished=lastChunk?(ret==0):(s_input.pos==s_input.size);
|
|
1249
|
-
} while (!finished);
|
|
1250
|
-
//if (s_input.pos!=s_input.size) _compress_error_return("Impossible: zstd only returns 0 when the input is completely consumed!");
|
|
1251
|
-
if (lastChunk)
|
|
1252
|
-
break;
|
|
903
|
+
}
|
|
904
|
+
while (1) {
|
|
905
|
+
s_output.pos=0;
|
|
906
|
+
ret=ZSTD_endStream(s,&s_output);
|
|
907
|
+
if (s_output.pos>0){
|
|
908
|
+
_stream_out_code_write(out_code,outStream_isCanceled,result,
|
|
909
|
+
(const unsigned char*)s_output.dst,s_output.pos);
|
|
1253
910
|
}
|
|
911
|
+
if (ret==0) break;
|
|
1254
912
|
}
|
|
1255
913
|
clear:
|
|
1256
914
|
#if (!IS_REUSE_compress_handle)
|
|
1257
|
-
if (0!=
|
|
1258
|
-
{
|
|
915
|
+
if (0!=ZSTD_freeCStream(s))
|
|
916
|
+
{ result=kCompressFailResult; if (strlen(errAt)==0) errAt="ZSTD_freeCStream()"; }
|
|
1259
917
|
#endif
|
|
1260
918
|
_check_compress_result(result,outStream_isCanceled,"_zstd_compress()",errAt);
|
|
1261
919
|
if (_temp_buf) free(_temp_buf);
|
|
@@ -1488,38 +1146,6 @@ int _default_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadN
|
|
|
1488
1146
|
LZHAM_COMP_LEVEL_BETTER,24,kDefaultCompressThreadNumber};
|
|
1489
1147
|
#endif//_CompressPlugin_lzham
|
|
1490
1148
|
|
|
1491
|
-
#ifdef _CompressPlugin_tuz
|
|
1492
|
-
#if (_IsNeedIncludeDefaultCompressHead)
|
|
1493
|
-
# include "tuz_enc.h" // "tinyuz/compress/tuz_enc.h" https://github.com/sisong/tinyuz
|
|
1494
|
-
#endif
|
|
1495
|
-
typedef struct TCompressPlugin_tuz{
|
|
1496
|
-
hdiff_TCompress base;
|
|
1497
|
-
tuz_TCompressProps props;
|
|
1498
|
-
} TCompressPlugin_tuz;
|
|
1499
|
-
static int _tuz_setParallelThreadNumber(hdiff_TCompress* compressPlugin,int threadNum){
|
|
1500
|
-
TCompressPlugin_tuz* plugin=(TCompressPlugin_tuz*)compressPlugin;
|
|
1501
|
-
plugin->props.threadNum=threadNum;
|
|
1502
|
-
return threadNum;
|
|
1503
|
-
}
|
|
1504
|
-
static hpatch_StreamPos_t _tuz_compress(const hdiff_TCompress* compressPlugin,
|
|
1505
|
-
const hpatch_TStreamOutput* out_code,
|
|
1506
|
-
const hpatch_TStreamInput* in_data){
|
|
1507
|
-
const TCompressPlugin_tuz* plugin=(const TCompressPlugin_tuz*)compressPlugin;
|
|
1508
|
-
tuz_TCompressProps props=plugin->props;
|
|
1509
|
-
if (props.dictSize>=in_data->streamSize)
|
|
1510
|
-
props.dictSize=(in_data->streamSize>1)?(tuz_size_t)(in_data->streamSize-1):1;
|
|
1511
|
-
# if (IS_NOTICE_compress_canceled)
|
|
1512
|
-
printf(" (used one tinyuz dictSize: %" PRIu64 " (input data: %" PRIu64 "))\n",
|
|
1513
|
-
(hpatch_StreamPos_t)props.dictSize,in_data->streamSize);
|
|
1514
|
-
# endif
|
|
1515
|
-
return tuz_compress(out_code,in_data,&props);
|
|
1516
|
-
}
|
|
1517
|
-
_def_fun_compressType(_tuz_compressType,"tuz");
|
|
1518
|
-
static const TCompressPlugin_tuz tuzCompressPlugin={
|
|
1519
|
-
{_tuz_compressType,_default_maxCompressedSize,_tuz_setParallelThreadNumber,_tuz_compress},
|
|
1520
|
-
{(1<<24),tuz_kMaxOfMaxSaveLength,kDefaultCompressThreadNumber}};
|
|
1521
|
-
#endif //_CompressPlugin_tuz
|
|
1522
|
-
|
|
1523
1149
|
#ifdef __cplusplus
|
|
1524
1150
|
}
|
|
1525
1151
|
#endif
|