diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-01-14 04:51:34 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-01-14 04:51:34 +0000 |
commit | ec9a859c76ce2819105e704aef892e41fa71877e (patch) | |
tree | 006dcc7aac3f10eb87d824f81d4346733a9796a2 /ext/zlib | |
parent | 377b85f2cbdc9f9142594b1a7c1f980c92102fc9 (diff) |
* ext/zlib/zlib.c (gzfile_check_footer): ISIZE (Input SIZE) in
gzip's header is the size of uncompressed input data modulo 2^32.
[ruby-core:34481] http://www.ietf.org/rfc/rfc1952.txt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30540 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/zlib')
-rw-r--r-- | ext/zlib/zlib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 40a2c79e60..36fc29fa18 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -2169,7 +2169,7 @@ gzfile_check_footer(struct gzfile *gz) if (gz->crc != crc) { rb_raise(cCRCError, "invalid compressed data -- crc error"); } - if (gz->z.stream.total_out != length) { + if ((int32_t)gz->z.stream.total_out != length) { rb_raise(cLengthError, "invalid compressed data -- length error"); } } |