You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.
Expected to see some errors if the library is fed with plaintext data. No dice. I see instead empty buffers (for convenience methods) and straight end event (for the zlib.create* streams).
$ echo'foo'> file.txt
$ gzip -c file.txt > file.txt.gz
$ node gunz.js file.txt
end of decompression
$ node gunz.js file.txt.gz
foo
end of decompression
$ node gunz2.js file.txt
$ node gunz2.js file.txt.gz
foo
The source js sources:
// gunz.jsvarzlib=require('zlib');varfs=require('fs');vargunzip=zlib.createGunzip();// same thing with zlib.createUnzip()varrs=fs.createReadStream(process.argv[2]);rs.pipe(gunzip);gunzip.on('data',function(data){console.log(data.toString());});gunzip.on('end',function(){console.log('end of decompression');});gunzip.on('error',function(err){console.error(err);});
Reproduced with node v0.6.17 under the latest Ubuntu and Windows 7. Presumably all the versions are affected. Under Ubuntu I reproduced it with 0.6.0, 0.6.5, 0.6.10, and 0.6.15 as well.
The text was updated successfully, but these errors were encountered:
@isaacs: 1565682 is a back-port of the changes to v0.6. A minor infidelity is that it also back-ports setDictionary() (it wasn't possible to exclude that commit without introducing tons of conflicts) but worst case, we simply comment out the NODE_SET_METHOD call.
Expected to see some errors if the library is fed with plaintext data. No dice. I see instead empty buffers (for convenience methods) and straight end event (for the zlib.create* streams).
The source js sources:
Reproduced with node v0.6.17 under the latest Ubuntu and Windows 7. Presumably all the versions are affected. Under Ubuntu I reproduced it with 0.6.0, 0.6.5, 0.6.10, and 0.6.15 as well.
The text was updated successfully, but these errors were encountered: