From f14133782b12c3f3998261a736b143b07acd237d Mon Sep 17 00:00:00 2001 From: takano32 Date: Mon, 1 Mar 2010 11:11:08 +0000 Subject: [PATCH] * ext/zlib/zlib.c (zstream_expand_buffer_into): remove compare different type values warning. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ ext/zlib/zlib.c | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 0a607d4b0f..1bd107ab16 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Mon Mar 1 20:07:06 2010 TAKANO Mitsuhiro (takano32) + + * ext/zlib/zlib.c (zstream_expand_buffer_into): remove compare different type values warning. + Mon Mar 1 17:42:45 2010 wanabe * configure.in (mingw): do not detect snprintf/vsnprintf. diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 3c50b99785..435a1a6a9f 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -59,7 +59,7 @@ struct zstream; struct zstream_funcs; static void zstream_init(struct zstream*, const struct zstream_funcs*); static void zstream_expand_buffer(struct zstream*); -static void zstream_expand_buffer_into(struct zstream*, int); +static void zstream_expand_buffer_into(struct zstream*, unsigned int); static void zstream_append_buffer(struct zstream*, const Bytef*, int); static VALUE zstream_detach_buffer(struct zstream*); static VALUE zstream_shift_buffer(struct zstream*, int); @@ -518,7 +518,7 @@ zstream_expand_buffer(struct zstream *z) } static void -zstream_expand_buffer_into(struct zstream *z, int size) +zstream_expand_buffer_into(struct zstream *z, unsigned int size) { if (NIL_P(z->buf)) { /* I uses rb_str_new here not rb_str_buf_new because @@ -2591,7 +2591,7 @@ rb_gzfile_set_mtime(VALUE obj, VALUE mtime) } else { val = rb_Integer(mtime); - gz->mtime = FIXNUM_P(val) ? FIX2INT(val) : rb_big2ulong(val); + gz->mtime = FIXNUM_P(val) ? FIX2UINT(val) : rb_big2ulong(val); } return mtime; }