From 512a35693b7819d6acc30a0e0b916c5ee7a88b5c Mon Sep 17 00:00:00 2001 From: akr Date: Wed, 23 Jun 2010 15:05:25 +0000 Subject: [PATCH] * ext/socket/raddrinfo.c (str_is_number): renamed from str_isnumber to avoid confusion to str_isnumber in ext/socket/getaddrinfo.c. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28410 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ ext/socket/raddrinfo.c | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 61f4db718b..beb97970fd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Jun 23 23:49:21 2010 Tanaka Akira + + * ext/socket/raddrinfo.c (str_is_number): renamed from str_isnumber to + avoid confusion to str_isnumber in ext/socket/getaddrinfo.c. + Wed Jun 23 23:45:31 2010 Yusuke Endoh * NEWS (stringio): new methods. [ruby-dev:41687] [Bug #3469] diff --git a/ext/socket/raddrinfo.c b/ext/socket/raddrinfo.c index a0a894ce47..99426ed371 100644 --- a/ext/socket/raddrinfo.c +++ b/ext/socket/raddrinfo.c @@ -97,7 +97,7 @@ ruby_getnameinfo__aix(const struct sockaddr *sa, size_t salen, ruby_getnameinfo__aix((sa), (salen), (host), (hostlen), (serv), (servlen), (flags)) #endif -static int str_isnumber(const char *); +static int str_is_number(const char *); #if defined(__APPLE__) /* fix [ruby-core:29427] */ @@ -110,7 +110,7 @@ ruby_getaddrinfo__darwin(const char *nodename, const char *servname, tmp_servname = servname; MEMCPY(&tmp_hints, hints, struct addrinfo, 1); if (nodename && servname) { - if (str_isnumber(tmp_servname) && atoi(servname) == 0) { + if (str_is_number(tmp_servname) && atoi(servname) == 0) { tmp_servname = NULL; #ifdef AI_NUMERICSERV if (tmp_hints.ai_flags) tmp_hints.ai_flags &= ~AI_NUMERICSERV; @@ -239,7 +239,7 @@ make_inetaddr(unsigned int host, char *buf, size_t len) } static int -str_isnumber(const char *p) +str_is_number(const char *p) { char *ep; @@ -329,7 +329,7 @@ rsock_getaddrinfo(VALUE host, VALUE port, struct addrinfo *hints, int socktype_h hostp = host_str(host, hbuf, sizeof(hbuf), &additional_flags); portp = port_str(port, pbuf, sizeof(pbuf), &additional_flags); - if (socktype_hack && hints->ai_socktype == 0 && str_isnumber(portp)) { + if (socktype_hack && hints->ai_socktype == 0 && str_is_number(portp)) { hints->ai_socktype = SOCK_DGRAM; } hints->ai_flags |= additional_flags;