diff options
author | katsu <katsu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-04-06 09:29:21 +0000 |
---|---|---|
committer | katsu <katsu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-04-06 09:29:21 +0000 |
commit | e393f0ad16f1f6646076ae9f38430422a72c800c (patch) | |
tree | 0695c65f376212b749a7496f09071b56f705bbb9 /ext/zlib | |
parent | add23cc22ee306d4aa3e2ec04883564554b5f582 (diff) | |
download | ruby-e393f0ad16f1f6646076ae9f38430422a72c800c.tar.gz |
* zlib.c (rb_gzreader_getc): the return value of GzipReader#getc must be unsigned.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3645 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 b89738de89..73efe8e01b 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -2387,7 +2387,7 @@ rb_gzreader_getc(obj) dst = gzfile_read(gz, 1); if (!NIL_P(dst)) { - dst = INT2FIX(RSTRING(dst)->ptr[0]); + dst = INT2FIX((unsigned int)(RSTRING(dst)->ptr[0]) & 0xff); } return dst; } |