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

zlib: expose zlib.crc32() #52692

Merged
merged 6 commits into from
May 2, 2024
Merged

zlib: expose zlib.crc32() #52692

merged 6 commits into from
May 2, 2024

Commits on Apr 25, 2024

  1. zlib: expose zlib.crc32()

    This patch exposes the crc32() function from zlib to user-land.
    
    It computes a 32-bit Cyclic Redundancy Check checksum of `data`. If
    `value` is specified, it is used as the starting value of the checksum,
    otherwise, 0 is used as the starting value.
    
    ```js
    const zlib = require('node:zlib');
    const { Buffer } = require('node:buffer');
    
    let crc = zlib.crc32('hello');  // 907060870
    crc = zlib.crc32('world', crc);  // 4192936109
    
    crc = zlib.crc32(Buffer.from('hello'));  // 907060870
    crc = zlib.crc32(Buffer.from('world'), crc);  // 4192936109
    ```
    joyeecheung committed Apr 25, 2024
    Configuration menu
    Copy the full SHA
    53fb0e4 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d9057fc View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d4fc5ca View commit details
    Browse the repository at this point in the history

Commits on Apr 26, 2024

  1. Configuration menu
    Copy the full SHA
    b26c0c6 View commit details
    Browse the repository at this point in the history
  2. fixup! zlib: expose zlib.crc32()

    Co-authored-by: Anna Henningsen <github@addaleax.net>
    joyeecheung and addaleax authored Apr 26, 2024
    Configuration menu
    Copy the full SHA
    905c481 View commit details
    Browse the repository at this point in the history

Commits on Apr 30, 2024

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