Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add parametrized testing #1448

Open
wants to merge 133 commits into
base: develop
Choose a base branch
from
Open

Commits on Jun 13, 2021

  1. Must use safe chunk copies due to inflateBack using the same allocati…

    …on for output and window. In this instance if too many bytes are written it will not correctly write matches with distances close to the window size.
    nmoinvaz authored and Dead2 committed Jun 13, 2021
    Configuration menu
    Copy the full SHA
    c79998f View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    6438064 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    11d7321 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    6cc2637 View commit details
    Browse the repository at this point in the history

Commits on Jun 21, 2021

  1. Change WITH_SANITIZER to be a multi-option parameter (for ccmake etc).

    Add support for selcting Thread sanitizer.
    Dead2 committed Jun 21, 2021
    Configuration menu
    Copy the full SHA
    89992df View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f0a801e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5d2ce27 View commit details
    Browse the repository at this point in the history
  4. Fix MSVC warnings in hash_head_0.c test

    iii-i authored and Dead2 committed Jun 21, 2021
    Configuration menu
    Copy the full SHA
    77966c0 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    3fdfedd View commit details
    Browse the repository at this point in the history
  6. [chunkset_neon] Don't use signed vector types.

    * There is no need to convert between unsigned and signed vector types. All relevant intrinsics have versions for all unsigned vector types.
    mtl1979 authored and Dead2 committed Jun 21, 2021
    Configuration menu
    Copy the full SHA
    61a5776 View commit details
    Browse the repository at this point in the history
  7. [chunkset_neon] Use vdupq_n_u64.

    * Using vdupq_n_u64 duplicates the unsigned 64-bit integer to two consecutive aligned memory locations in stack so compiler can use wider load instructions.
      All different-sized general-purpose registers overlay on ARM/AArch64, so any vector cast is no-op in assembly.
    mtl1979 authored and Dead2 committed Jun 21, 2021
    Configuration menu
    Copy the full SHA
    089b2e7 View commit details
    Browse the repository at this point in the history
  8. [chunkcopy_safe] Don't call chunkcopy().

    * chunkcopy() can read or write more than the safe length if the length is not multiple of chunk size.
    mtl1979 authored and Dead2 committed Jun 21, 2021
    Configuration menu
    Copy the full SHA
    c4511df View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    74b4165 View commit details
    Browse the repository at this point in the history

Commits on Jun 22, 2021

  1. Configuration menu
    Copy the full SHA
    3a66bc7 View commit details
    Browse the repository at this point in the history

Commits on Jun 25, 2021

  1. Version 2.0.5

    - Fix inflate corruption on aarch64 zlib-ng#1008
    - Fix MSVC warnings zlib-ng#1002 zlib-ng#1013
    - Minor chunkset improvements zlib-ng#1000 zlib-ng#994 zlib-ng#1015
    - Minor cleanup zlib-ng#997
    - Add CI test for pigz on aarch64 zlib-ng#1004
    - Cmake improvements zlib-ng#996
    Dead2 committed Jun 25, 2021
    Configuration menu
    Copy the full SHA
    c69f78b View commit details
    Browse the repository at this point in the history

Commits on Aug 11, 2021

  1. Fix Z_SOLO mode

    Without this patch, #include <zlib.h> with Z_SOLO defined
    (e.g. while building perl 5.34.0) fails because of use of
    undefined types.
    berolinux authored and Dead2 committed Aug 11, 2021
    Configuration menu
    Copy the full SHA
    ac97954 View commit details
    Browse the repository at this point in the history

Commits on Dec 24, 2021

  1. Add new crc32 unit test

    mscastanho authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    59c8b88 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e08cb8e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    18a4712 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    de570b8 View commit details
    Browse the repository at this point in the history
  5. IBM Z: Fix building outside of a source directory

    Do not use relative includes, since they are valid only within the
    source directory. Rely on the build system to pass the necessary
    include flags instead.
    iii-i authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    432d00d View commit details
    Browse the repository at this point in the history
  6. ENH: Transition to Ubuntu 18.04 in GitHub actions workflows

    Transition to Ubuntu 18.04 in `GitHub` actions workflows.
    
    Fixes:
    ```
    Ubuntu 16.04 Clang
    This request was automatically failed because there were no enabled runners online to process the request for more than 1 days.
    
    Ubuntu 16.04 GCC
    This request was automatically failed because there were no enabled runners online to process the request for more than 1 days.
    ```
    
    reported for example at:
    https://github.com/zlib-ng/zlib-ng/actions/runs/1326434358
    
    Official `GitHub` notice related to the removal of the 16.04 virtual
    environments:
    https://github.blog/changelog/2021-04-29-github-actions-ubuntu-16-04-lts-virtual-environment-will-be-removed-on-september-20-2021/
    jhlegarreta authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    49b531b View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    07d7354 View commit details
    Browse the repository at this point in the history
  8. Added unit test to ensure that inflate with adler32 hash works on pre…

    …viously failed test case.
    nmoinvaz authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    8e22abd View commit details
    Browse the repository at this point in the history
  9. [arm] Disable ACLE, UNALIGNED_OK and UNALIGNED64_OK on armv7 and earl…

    …ier.
    
    * armv7 has partial support for unaligned reads, but compiler might use instructions that do not support unaligned accesses
    mtl1979 authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    13f155e View commit details
    Browse the repository at this point in the history
  10. Fill out gzheader before calling deflateSetHeader for better code cov…

    …erage in example.
    nmoinvaz authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    3d7381f View commit details
    Browse the repository at this point in the history
  11. Added build system check for posix_memalign support.

    Co-authored-by: concatime <concatime@users.noreply@github.com>
    Co-authored-by: Mika Lindqvist <postmaster@raasu.org>
    3 people authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    7bf46bb View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    022307b View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    1ffbd26 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    5048bde View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    8cf93da View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    2f22eb6 View commit details
    Browse the repository at this point in the history
  17. Fix minor formatting issues

    From ITK PR: InsightSoftwareConsortium/ITK#2803
    CI check: https://github.com/InsightSoftwareConsortium/ITK/runs/3864083025
    
    commit 5434d42 adds bad whitespace:
    README.md:223: new blank line at EOF.
    
    commit 5434d42 is not allowed; missing newline at the end of file in .gitattributes.
    dzenanz authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    cab06b0 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    e945928 View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    f172e34 View commit details
    Browse the repository at this point in the history
  20. Fixed undefined behavior of isgraph when character is not in the rang…

    …e 0 through 0xFF inclusive.
    nmoinvaz authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    141ca90 View commit details
    Browse the repository at this point in the history
  21. Fixed missing enclosing parentheses for ZSWAP64 in zutil.h to avoid e…

    …rroneous result in inffast.c.
    cenobit authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    7445409 View commit details
    Browse the repository at this point in the history
  22. Standardize crc32_stub

    Reorganize statements inside crc32_stub() to match more closely the format
    used for other function stubs in functable.c.
    mscastanho authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    5bbf9ef View commit details
    Browse the repository at this point in the history
  23. Configuration menu
    Copy the full SHA
    cdc8033 View commit details
    Browse the repository at this point in the history
  24. Fix UB in inffast.c when not using window

    When not using window, `window + wsize` applies a zero offset to a null pointer, which is undefined behavior.
    atdt authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    a9f2e15 View commit details
    Browse the repository at this point in the history
  25. COMP: Fix data loss warning

    Fix data loss warning.
    
    Fixes:
    ```
    itkzlib-ng/inflate.c(1209,24): warning C4267: '=': conversion from 'size_t' to 'unsigned long', possible loss of data
    itkzlib-ng/inflate.c(1210,26): warning C4267: '=': conversion from 'size_t' to 'unsigned long', possible loss of data
    ```
    jhlegarreta authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    a0beadd View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    f1b0a04 View commit details
    Browse the repository at this point in the history
  27. IBM Z: Run DFLTCC tests on the self-hosted builder

    * Use the self-hosted builder instead of ubuntu-latest.
    * Drop qemu-related settings from DFLTCC configurations.
    * Install codecov only for the current user, since the self-hosted
      builder runs under a restricted non-root account.
    * Use actions/checkout@v2 for configure checks, since for some reason
      actions/checkout@v1 cannot find git on the self-hosted builder.
    * Update the testing section of the DFLTCC README.
    * Add the infrastructure code for the self-hosted builder.
    iii-i authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    2faaf5b View commit details
    Browse the repository at this point in the history
  28. Fix deflateBound and compressBound returning very small size estimates.

    Remove workaround in switchlevels.c, so we do actual testing of this.
    Use named defines instead of magic numbers where we can.
    Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    8a378ba View commit details
    Browse the repository at this point in the history
  29. Link crc32_test and infcover with $(CFLAGS)

    This fixes link failures when using CFLAGS=-m31 on IBM Z. All the
    other tests are already linked this way.
    iii-i authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    a38184e View commit details
    Browse the repository at this point in the history
  30. IBM Z: Do not check inflateGetDictionary() with DFLTCC

    The zlib manual does not specify a strict contract for
    inflateGetDictionary(), it merely says that it "Returns the sliding
    dictionary being maintained by inflate", which is an implementation
    detail. IBM Z inflate's behavior differs from that of software, and
    may change in the future to boot.
    iii-i authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    b1f726a View commit details
    Browse the repository at this point in the history
  31. IBM Z: Adjust compressBound() for DFLTCC

    When DFLTCC was introduced, deflateBound() was adjusted, but
    compressBound() was not, leading to compression failures when using
    compressBound() + compress() with poorly compressible data.
    iii-i authored and Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    5c7d5a2 View commit details
    Browse the repository at this point in the history
  32. Configuration menu
    Copy the full SHA
    a564bcd View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    49de90d View commit details
    Browse the repository at this point in the history
  34. Version 2.0.6

     - Fix hangs on macOS zlib-ng#1031
     - Fix minideflate write buffers being overwritten zlib-ng#1060
     - Fix deflateBound and compressBound returning too small size estimates zlib-ng#1049 zlib-ng#1071
     - Fix incorrect function declaration warning zlib-ng#1080
     - Fix build problems when building outside of source dir zlib-ng#1049
     - Fix build problems on arm2-7 zlib-ng#1030
     - Fixed some compile warnings zlib-ng#1020 zlib-ng#1036 zlib-ng#1037 zlib-ng#1048
     - Improved posix memalign support zlib-ng#888
     - Improvements to testing zlib-ng#637 zlib-ng#1026 zlib-ng#1032 zlib-ng#1035 zlib-ng#1049 zlib-ng#1051 zlib-ng#1056 zlib-ng#1063 zlib-ng#1067 zlib-ng#1079
     - Improvements for integration into other projects zlib-ng#1022 zlib-ng#1042
     - Code style fixes zlib-ng#637 zlib-ng#1040 zlib-ng#1050 zlib-ng#1075
    Dead2 committed Dec 24, 2021
    Configuration menu
    Copy the full SHA
    b56a2fd View commit details
    Browse the repository at this point in the history

Commits on Dec 26, 2022

  1. Configuration menu
    Copy the full SHA
    d14adcc View commit details
    Browse the repository at this point in the history

Commits on Dec 27, 2022

  1. Fix UBSAN's cry afoul

    Technically, we weren't actually doing this the way C wants us to,
    legally.  The zmemcpy's turn into NOPs for pretty much all > 0
    optimization levels and this gets us defined behavior with the
    sanitizer, putting the optimized load by arbitrary alignment into the
    compiler's hands instead of ours.
    
    Backport note: Replaced zmemcpy with direct memcpy, as that is what we
    end up with in a later commit anyway.
    KungFuJesus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    237a559 View commit details
    Browse the repository at this point in the history
  2. Allow bypassing runtime feature check of TZCNT instructions.

    * This avoids conditional branch when it's known at build time that TZCNT instructions are always supported
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    fb8b4be View commit details
    Browse the repository at this point in the history
  3. [README] Add missing FORCE_SSE2 for CMake.

    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    7ed116f View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    c60eb3a View commit details
    Browse the repository at this point in the history
  5. macOs M1 build fix on arm cpu checks.

    devnexen authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    f72b49e View commit details
    Browse the repository at this point in the history
  6. Fix a latent issue with chunkmemset

    It would seem that on some platforms, namely those which are
    !UNALIGNED64_OK, there was a likelihood of chunkmemset_safe_c copying all
    the bytes before passing control flow to chunkcopy, a function which is
    explicitly unsafe to be called with a zero length copy.
    
    This fixes that bug for those platforms.
    KungFuJesus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    1d54221 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    221bfd1 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    9f97d13 View commit details
    Browse the repository at this point in the history
  9. Added unit test against CVE-2018-25032.

    Sample input from https://www.openwall.com/lists/oss-security/2022/03/26/1.
    
    Co-authored-by: Tavis Ormandy <taviso@users.noreply.github.com>
    2 people authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    1e980c5 View commit details
    Browse the repository at this point in the history
  10. Added unit test against CVE-2018-25032 with default strategy.

    Co-authored-by: Eric Biggers <ebiggers@kernel.org>
    2 people authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    746fc54 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    5a687a2 View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    421634b View commit details
    Browse the repository at this point in the history
  13. Remove unistd.h include from gzguts.h which is already included from …

    …zconf.h via zlib.h.
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    46d8997 View commit details
    Browse the repository at this point in the history
  14. abicheck.sh: zlib-ng is a bash script, not a sh script, don't hardcod…

    …e shell when running configure
    dankegel authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    832873f View commit details
    Browse the repository at this point in the history
  15. Add one extra byte to return value of compressBound and deflateBound …

    …for small lengths due to shift returning 0.
    
    * Treat 0 byte input as 1 byte input when calculating compressBound and deflateBound
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    1d0ab7e View commit details
    Browse the repository at this point in the history
  16. Add test for issue zlib-ng#1235.

    * Test both compressBound() and deflateBound() as those share same code fragment.
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    666b32e View commit details
    Browse the repository at this point in the history
  17. Disable LTO in CMake

    phprus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    0d5d2a4 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    f01f889 View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    aa927be View commit details
    Browse the repository at this point in the history
  20. Configuration menu
    Copy the full SHA
    cbb0307 View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    f99cef6 View commit details
    Browse the repository at this point in the history
  22. Configuration menu
    Copy the full SHA
    53cc7fb View commit details
    Browse the repository at this point in the history
  23. Use large default buffer size for minideflate to match minigzip use o…

    …f GZBUFSIZE.
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    6f2939e View commit details
    Browse the repository at this point in the history
  24. Added support for -k keep argument to minideflate. By default minidef…

    …late will now delete the input file.
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    e67c9ff View commit details
    Browse the repository at this point in the history
  25. Append extension to output file path based on window_bits when compre…

    …ssing and remove extension from output file path when decompressing.
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    69172e3 View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    fe9af76 View commit details
    Browse the repository at this point in the history
  27. Configuration menu
    Copy the full SHA
    f0d0791 View commit details
    Browse the repository at this point in the history
  28. Configuration menu
    Copy the full SHA
    882d934 View commit details
    Browse the repository at this point in the history
  29. Configuration menu
    Copy the full SHA
    9523572 View commit details
    Browse the repository at this point in the history
  30. Remove unused chunkmemset_1 code.

    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    bdc7a43 View commit details
    Browse the repository at this point in the history
  31. The names CMAKE_INTERPROCEDURAL_OPTIMIZATION_* must be uppercase.

    Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
    phprus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    c102886 View commit details
    Browse the repository at this point in the history
  32. Make directory for output files.

    Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
    phprus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    df6957c View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    24d6fdb View commit details
    Browse the repository at this point in the history
  34. remove UNROLL_MORE as suggested

    landfillbaby authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    4ef070a View commit details
    Browse the repository at this point in the history
  35. early return as requested

    landfillbaby authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    f11f537 View commit details
    Browse the repository at this point in the history
  36. CMakeLists.txt: fix version in zlib.pc when building statically

    When building statically (i.e. with BUILD_SHARED_LIBS=OFF),
    ZLIB_FULL_VERSION is not set resulting in an empty version in zlib.pc
    and the following build failure with transmission:
    
    checking for ZLIB... configure: error: Package requirements (zlib >= 1.2.3) were not met:
    
    Package dependency requirement 'zlib >= 1.2.3' could not be satisfied.
    Package 'zlib' has version '', required version is '>= 1.2.3'
    
    Fixes:
     - http://autobuild.buildroot.org/results/b3b882482f517726e5c780ba4c37818bd379df82
    
    Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
    ffontaine authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    ecc094a View commit details
    Browse the repository at this point in the history
  37. Add public compile definition for zlib-ng API so that other projects …

    …that use CMake and link against the zlib project can easily determine whether or not to include "zlib-ng.h" or "zlib.h".
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    287b763 View commit details
    Browse the repository at this point in the history
  38. Handle invalid windowBits in init functions

    Negative windowBits arguments are eventually turned positive in
    deflateInit2_ and inflateInit2_ (more precisely in inflateReset2).
    Such values are used to indicate that raw deflate/inflate should
    be performed.
    
    If a user supplies INT32_MIN for windowBits, the code will perform
    -INT32_MIN which does not fit into int32_t. In fact, this is
    undefined behavior in C and should be avoided.
    
    Clearly this is a user error, but given the careful validation of
    input arguments a few lines later in deflateInit2_ I think this
    might be of interest.
    
    Proof of Concept:
    
    - Compile zlib-ng with gcc -ftrapv or -fsanitize=undefined
    - Compile and run this program:
    
    ```
     #include <limits.h>
     #include <stdio.h>
     #include <zlib-ng.h>
    
     int main(void) {
      zng_stream de_stream = { 0 }, in_stream = { 0 };
      int result;
    
      result = zng_deflateInit2(&de_stream, 0, Z_DEFLATED, INT32_MIN,
          MAX_MEM_LEVEL, Z_DEFAULT_STRATEGY);
      printf("zng_deflateInit2: %d\n", result);
    
      result = zng_inflateInit2(&in_stream, INT32_MIN);
      printf("zng_inflateInit2: %d\n", result);
    
      return 0;
     }
    ```
    stoeckmann authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    72c430b View commit details
    Browse the repository at this point in the history
  39. Extend GZIP conditional

    If gzip support has been disabled during compilation then also
    consider gzip relevant states as invalid in deflateStateCheck.
    
    Also the gzip state definitions can be removed.
    
    This change leads to failure in test/example, and I am not sure
    what the GZIP conditional is trying to achieve. All gzip related
    functions are still defined in zlib.h
    
    Alternative approach is to remove the GZIP define.
    stoeckmann authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    f8c8bb7 View commit details
    Browse the repository at this point in the history
  40. In compatibility mode, always define z_crc_t as uint32_t for backward…

    …s compatibility.
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    19059d2 View commit details
    Browse the repository at this point in the history
  41. Configuration menu
    Copy the full SHA
    a61fbf9 View commit details
    Browse the repository at this point in the history
  42. Configuration menu
    Copy the full SHA
    3bcda52 View commit details
    Browse the repository at this point in the history
  43. Don't use unaligned access for memcpy instructions due to GCC 11 assu…

    …ming it is aligned in certain instances.
    
    Backport note: Removed a lot of the original commit due to merge conflicts
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    8f4e8f2 View commit details
    Browse the repository at this point in the history
  44. Configuration menu
    Copy the full SHA
    6ad3bdf View commit details
    Browse the repository at this point in the history
  45. Fixed functions declared without a prototype warning in tools.

      tools/maketrees.c:101:29: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
    static void gen_trees_header()
    
      tools/makecrct.c:65:27: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
    static void make_crc_table()
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    4a2fb17 View commit details
    Browse the repository at this point in the history
  46. Treat arm64 as aarch64 for Apple M1.

    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    6890dfb View commit details
    Browse the repository at this point in the history
  47. cmake: respect custom RC flags and delete GCC_WINDRES

    Before this patch, `zlib.rc` was compiled using a manual command [1] when
    using the MinGW (and MSYS/Cygwin) toolchains. This method ignores
    `CMAKE_RC_FLAGS` and offers no other way to pass a custom flag, breaking
    the build in cases where a custom `windres` option is required. E.g.
    `--target=` or `-I` on some platforms and configuration, in particular
    with `llvm-windres`.
    
    This patch deletes the special case for these toolchains and lets CMake
    compile the `.rc` file the default way used for all Windows targets.
    
    I'm not entirely sure why this special case was added back in 2011. The
    need to pass `-DGCC_WINDRES` is my suspect. We can resolve this much
    simpler by adding this line for the targets that require it:
       set(CMAKE_RC_FLAGS "${CMAKE_RC_FLAGS} -DGCC_WINDRES")
    
    But, the `.rc` line protected by `GCC_WINDRES`, these days work just fine
    with `windres`. Moreover, that protected line are oboslete flags from the
    16-bit era, which for a long time have no effect, as documented here:
    <https://docs.microsoft.com/windows/win32/menurc/common-resource-attributes>
    
    So, this patch deletes `GCC_WINDRES` from the project entirely.
    
    [1] dc5a43e
    vszakats authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    68a9d16 View commit details
    Browse the repository at this point in the history
  48. If the extra field was larger than the space the user provided with

    inflateGetHeader(), and if multiple calls of inflate() delivered
    the extra header data, then there could be a buffer overflow of the
    provided space. This commit assures that provided space is not
    exceeded.
    
    See zlib-ng#1323.
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    d277234 View commit details
    Browse the repository at this point in the history
  49. Add CVE-2022-37434 test.

    Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
    phprus authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    5e037c8 View commit details
    Browse the repository at this point in the history
  50. Actually run configure CI on macOS with GCC

    `gcc` is an alias for Apple Clang on macOS.  See for example https://github.com/zlib-ng/zlib-ng/runs/7963904948?check_suite_focus=true
    ```
    gcc -O2  -std=c11 -Wall -fPIC -DNDEBUG -DHAVE_POSIX_MEMALIGN -DWITH_GZFILEOP -fno-semantic-interposition -DHAVE_VISIBILITY_HIDDEN -DHAVE_VISIBILITY_INTERNAL -DHAVE_BUILTIN_CTZ -DHAVE_BUILTIN_CTZLL -DX86_FEATURES -DX86_AVX2 -DX86_AVX2_ADLER32 -DX86_AVX_CHUNKSET -DX86_AVX512 -DX86_AVX512_ADLER32 -DX86_MASK_INTRIN -DX86_AVX512VNNI -DX86_AVX512VNNI_ADLER32 -DX86_SSE41 -DX86_SSE42_CRC_HASH -DX86_SSE42_ADLER32 -DX86_SSE42_CRC_INTRIN -DX86_SSE2 -DX86_SSE2_CHUNKSET -DX86_SSSE3 -DX86_SSSE3_ADLER32 -DX86_PCLMULQDQ_CRC -DPIC -I/Users/runner/work/zlib-ng/zlib-ng -c -o adler32.lo /Users/runner/work/zlib-ng/zlib-ng/adler32.c
    clang: warning: argument unused during compilation: '-fno-semantic-interposition' [-Wunused-command-line-argument]
    ```
    
    In order to use the real GCC you have to call `gcc-9`, `gcc-10`, or `gcc-11`: https://github.com/actions/runner-images/blob/06dd4c14e4aa8c14febdd8d6cf123b8d770b4e4a/images/macos/macos-11-Readme.md#language-and-runtime.
    giordano authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    12dd5d5 View commit details
    Browse the repository at this point in the history
  51. [Compat] Don't use uint32_t for z_crc_t

    * We don't include stdint.h as it must be included before stdarg.h and other headers might include stdarg.h before us
    
    See zlib-ng#1342
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    3d209cc View commit details
    Browse the repository at this point in the history
  52. Configuration menu
    Copy the full SHA
    c9a2a91 View commit details
    Browse the repository at this point in the history
  53. Configuration menu
    Copy the full SHA
    dec455c View commit details
    Browse the repository at this point in the history
  54. Make visibility tests run the same way as the other tests.

    Fix indentation.
    Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    66011c9 View commit details
    Browse the repository at this point in the history
  55. Configuration menu
    Copy the full SHA
    ff1e2cb View commit details
    Browse the repository at this point in the history
  56. Use short decompress option name for gzip compatibility. zlib-ng#1347

    Long option names in BusyBoxy is an optional feature, so use short option
    names by default.
    nmoinvaz authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    5157cab View commit details
    Browse the repository at this point in the history
  57. Fix typo in README.md

    ccawley2011 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    cd823a7 View commit details
    Browse the repository at this point in the history
  58. Configuration menu
    Copy the full SHA
    7e61ee2 View commit details
    Browse the repository at this point in the history
  59. [MinGW] Disable GCC warning about using MS format specifiers in ISO C…

    … conformant code
    mtl1979 authored and Dead2 committed Dec 27, 2022
    Configuration menu
    Copy the full SHA
    b0b7d78 View commit details
    Browse the repository at this point in the history
  60. Configuration menu
    Copy the full SHA
    910a288 View commit details
    Browse the repository at this point in the history
  61. Configuration menu
    Copy the full SHA
    7a1c8ef View commit details
    Browse the repository at this point in the history

Commits on Jan 13, 2023

  1. IBM zSystems DFLTCC: Fix updating strm.adler

    inflate() does not update strm.adler with DFLTCC.
    deflate() updates strm.adler even for raw streams.
    Fix by adding wrap checks.
    iii-i authored and Dead2 committed Jan 13, 2023
    Configuration menu
    Copy the full SHA
    1d17bfa View commit details
    Browse the repository at this point in the history

Commits on Feb 8, 2023

  1. Remove WindowBits check for level 1

    rhpvorderman authored and Dead2 committed Feb 8, 2023
    Configuration menu
    Copy the full SHA
    02cf11e View commit details
    Browse the repository at this point in the history
  2. Remove gz_intmax implementation, since INT_MAX is always available in…

    … modern C implementations.
    Dead2 committed Feb 8, 2023
    Configuration menu
    Copy the full SHA
    cfbad07 View commit details
    Browse the repository at this point in the history

Commits on Feb 9, 2023

  1. Configuration menu
    Copy the full SHA
    31a2a1c View commit details
    Browse the repository at this point in the history

Commits on Feb 10, 2023

  1. Backport latest CI workflows from 'develop'.

    Removed tests for features not supported in 2.0.x:
    - cxx related settings, as stable does not use gtest/gbench.
    - Emscripten
    - Add_subdirectory
    - Symbol prefix
    - oss-fuzz, their buildfile is incompatible with this branch
    Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    b80403b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ba7dc4f View commit details
    Browse the repository at this point in the history
  3. Update abicheck

    Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    0a73214 View commit details
    Browse the repository at this point in the history
  4. Adjust thread counts for compiles and tests to avoid under-utilizatio…

    …n and congestion.
    
    The free Github Actions VMs have 2 cores, the dedicated s390x VM has 4 cores.
    Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    f0417fb View commit details
    Browse the repository at this point in the history
  5. Use _msan_unposion to unposion end of window for when it needs to rea…

    …d the past < chunksize bytes in the window. See zlib-ng#1245.
    
    Co-authored-by: Adam Stylinski <kungfujesus06@gmail.com>
    
    Backported from commit c882034.
    nmoinvaz authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    23df8e7 View commit details
    Browse the repository at this point in the history
  6. IBM Z DFLTCC: Test with MSan

    * Add __msan_unpoison() calls to DFLTCC inline assembly.
    * Make parameter block sizes symbolic constants.
    * Move dfltcc() definition after struct dfltcc_param_v0 definition.
    
    Backported from commit 1f5ddcc.
    iii-i authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    3701d87 View commit details
    Browse the repository at this point in the history
  7. Fix crash when gzsetparams() attempted for transparent write.

    gzsetparams() now returns a Z_STREAM_ERROR in this case.
    madler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    9426e01 View commit details
    Browse the repository at this point in the history
  8. Fix bug in deflateBound() for level 0 and memLevel 9.

    memLevel 9 would cause deflateBound() to assume the use of fixed
    blocks, even if the compression level was 0, which forces stored
    blocks. That could result in a bound less than the size of the
    compressed data. Now level 0 always uses the stored blocks bound.
    madler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    5846fb4 View commit details
    Browse the repository at this point in the history
  9. Remove redundant check in gz_look().

    Mark Adler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    1867d7f View commit details
    Browse the repository at this point in the history
  10. Add WIN32_LEAN_AND_MEAN for windows.h include.

    Mark Adler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    f7e94b8 View commit details
    Browse the repository at this point in the history
  11. Fix bug in block type selection when Z_FIXED used.

    A fixed block could be chosen when a stored block was smaller. Now
    the smaller of the two is always chosen.
    Mark Adler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    fe9e685 View commit details
    Browse the repository at this point in the history
  12. Have infback() deliver all of the available output up to any error.

    Mark Adler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    f7f863c View commit details
    Browse the repository at this point in the history
  13. Have build test report library version if it doesn't match zlib.h.

    Mark Adler authored and Dead2 committed Feb 10, 2023
    Configuration menu
    Copy the full SHA
    f601a29 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    d35a28b View commit details
    Browse the repository at this point in the history

Commits on Feb 11, 2023

  1. Configuration menu
    Copy the full SHA
    a073e95 View commit details
    Browse the repository at this point in the history

Commits on Mar 7, 2023

  1. Version 2.0.7

    Changes since 2.0.6:
    - Fix CVE-2022-37434 zlib-ng#1328
    - Fix chunkmemset zlib-ng#1196
    - Fix deflateBound too small zlib-ng#1236
    - Fix Z_SOLO zlib-ng#1263
    - Fix ACLE variant of crc32 zlib-ng#1274
    - Fix inflateBack zlib-ng#1311
    - Fix deflate_quick windowsize zlib-ng#1431
    - Fix DFLTCC bugs related to adler32 zlib-ng#1349 and zlib-ng#1390
    - Fix warnings zlib-ng#1194 zlib-ng#1312 zlib-ng#1362
    - MacOS build fix zlib-ng#1198
    - Add invalid windowBits handling zlib-ng#1293
    - Support for Force TZCNT zlib-ng#1186
    - Support for aligned_alloc() zlib-ng#1360
    - Minideflate improvements zlib-ng#1175 zlib-ng#1238
    - Dont use unaligned access for memcpy zlib-ng#1309
    - Build system zlib-ng#1209 zlib-ng#1233 zlib-ng#1267 zlib-ng#1273 zlib-ng#1278 zlib-ng#1292 zlib-ng#1316 zlib-ng#1318 zlib-ng#1365
    - Test improvements zlib-ng#1208 zlib-ng#1227 zlib-ng#1241 zlib-ng#1353
    - Cleanup zlib-ng#1266
    - Documentation zlib-ng#1205 zlib-ng#1359
    - Misc improvements zlib-ng#1294 zlib-ng#1297 zlib-ng#1306 zlib-ng#1344 zlib-ng#1348
    - Backported zlib fixes
    - Backported CI workflows from Develop branch
    Dead2 committed Mar 7, 2023
    Configuration menu
    Copy the full SHA
    98ea610 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f636a09 View commit details
    Browse the repository at this point in the history