Bzip core dumps #2

Closed
OrangeDog opened this Issue Oct 4, 2011 · 5 comments

Projects

None yet

2 participants

@OrangeDog
var zip = new bzgz2.Bzip();
zip.init({level: 4});
zip.end();

error:

assertion "ret == BZ_FINISH_OK" failed: file "../compress.cc", line 540, function: int Bzip::BzipEnd(char**, int*)
Aborted (core dumped)

The same code using Gzip() instead does not cause this error.

NodeJS v0.4.11, libbz2-devel 1.0.6-2 (cygwin)

@Woodya
Owner
Woodya commented Oct 4, 2011

so, you're trying to create an empty bz2 file?
i can look into why that fails i guess. are you really trying to do this? or
just came across this?
-w

On Tue, Oct 4, 2011 at 7:38 AM, OrangeDog <
reply@reply.github.com>wrote:

var zip = new bzgz2.Bzip();
zip.init({level: 4});
zip.end();

error:

assertion "ret == BZ_FINISH_OK" failed: file "../compress.cc", line 540,
function: int Bzip::BzipEnd(char*, int)
Aborted (core dumped)

The same code using Gzip() instead does not cause this error.

NodeJS v0.4.11, libbz2-devel 1.0.6-2 (cygwin)

Reply to this email directly or view it on GitHub:
#2

@OrangeDog

There being no documentation on the subject, I was end()ing them when disposing of them lest they leak.

Let alone the undocumented difference between G and B, it really should throw a JS exception rather than dumping core. Behaviour of the latter sort is completely unacceptable in a production environment.

@OrangeDog OrangeDog closed this Oct 4, 2011
@OrangeDog OrangeDog reopened this Oct 4, 2011
@OrangeDog

Actually, I've just modified your test.js to use Bzip and exactly the same error occurs.

@OrangeDog

Also on CentOS 5.6 (x64), bzip2-libs 1.0.3

$ node test.js LICENSE
Got : 1125
File opened
Compressed chunk size : 0
assertion "ret == BZ_FINISH_OK" failed: file "../compress.cc", line 540, function: int Bzip::BzipEnd(char**, int*)
Aborted (core dumped)
@Woodya Woodya closed this Oct 9, 2011
@OrangeDog

This problem seems to be resolved with version 0.1.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment