Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

zlib fails on large files #1929

Closed
cskr opened this issue Oct 24, 2011 · 1 comment
Closed

zlib fails on large files #1929

cskr opened this issue Oct 24, 2011 · 1 comment
Assignees
Labels

Comments

@cskr
Copy link

cskr commented Oct 24, 2011

Create a 695 MB file with,

dd if=/dev/urandom of=test.iso bs=1024 count=$((1024*695))

Compress it with,

var zlib = require('zlib');

var gzip = zlib.createGzip();
var fs = require('fs');
var inp = fs.createReadStream('test.iso');
var out = fs.createWriteStream('out.iso.gz');

inp.pipe(gzip).pipe(out);

The compressed file is corrupted.

@isaacs
Copy link

isaacs commented Oct 24, 2011

Thanks for the report and test case.

Investigating.

@ghost ghost assigned isaacs Oct 24, 2011
@isaacs isaacs closed this as completed in 4c5751b Oct 24, 2011
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants