Skip to content

bzip2 CRC error: incompatibility with command line bunzip2 v 1.0.6 #21

@hwinkler

Description

@hwinkler

Using compressjs@1.0.3 and node v 11.4.0

compressjs.Bzip2 can produce output that the bunzip2 command line program, v 1.0.6 as distributed with Ubuntu 18.10, declares to have a CRC error.

The attached repro case compresses a large json file using Bzip2, once with blocksize 800k, and again with blocksize 900k.

bunzip2 of the compressed file of block size 800k succeeds.
bunzip2 of the compressed file of block size 900k fails.

error Error: Command failed: bunzip2 -t message.9.json.bz2
bunzip2: message.9.json.bz2: data integrity (CRC) error in data

To run the repro case, bunzip2 must be on your path. Then run

node index.js

repro.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions