diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-05-30 14:05:36 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-05-30 14:05:36 +0000 |
commit | f2e31d9f00bf60c978cfa0fb85cf64c1ed938610 (patch) | |
tree | c6d2e30eb926737969c8ae7c72612321c1a4a4e4 /ext/socket/raddrinfo.c | |
parent | fc58550b267abad481512b035baa065ce2399778 (diff) | |
download | ruby-f2e31d9f00bf60c978cfa0fb85cf64c1ed938610.tar.gz |
raddrinfo.c: fix modifier
* ext/socket/raddrinfo.c (host_str, port_str): fix length modifier
to size_t.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55220 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket/raddrinfo.c')
-rw-r--r-- | ext/socket/raddrinfo.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/socket/raddrinfo.c b/ext/socket/raddrinfo.c index f18e278323..b0c80399de 100644 --- a/ext/socket/raddrinfo.c +++ b/ext/socket/raddrinfo.c @@ -458,7 +458,7 @@ host_str(VALUE host, char *hbuf, size_t hbuflen, int *flags_ptr) if (flags_ptr) *flags_ptr |= AI_NUMERICHOST; } else if (len >= hbuflen) { - rb_raise(rb_eArgError, "hostname too long (%ld)", + rb_raise(rb_eArgError, "hostname too long (%"PRIdSIZE")", len); } else { @@ -489,7 +489,7 @@ port_str(VALUE port, char *pbuf, size_t pbuflen, int *flags_ptr) SafeStringValue(port); RSTRING_GETMEM(port, serv, len); if (len >= pbuflen) { - rb_raise(rb_eArgError, "service name too long (%ld)", + rb_raise(rb_eArgError, "service name too long (%"PRIdSIZE")", len); } memcpy(pbuf, serv, len); |