diff --git a/ChangeLog b/ChangeLog index 05fff4f323..3037125879 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun Jan 25 16:35:44 2009 Tanaka Akira + + * ext/socket/socket.c (socket_s_ip_address_list): renamed from + socket_s_list_ip_address. [ruby-dev:37806] + Sun Jan 25 12:17:21 2009 Nobuyoshi Nakada * cygwin/GNUmakefile.in (RUBYDEF): needs read-only section too. diff --git a/ext/socket/socket.c b/ext/socket/socket.c index 43d4250b04..20631e9da7 100644 --- a/ext/socket/socket.c +++ b/ext/socket/socket.c @@ -1427,13 +1427,13 @@ sockaddr_obj(struct sockaddr *addr) /* * call-seq: - * Socket.list_ip_address => array + * Socket.ip_address_list => array * * Returns local IP addresses as an array. * * The array contains AddrInfo objects. * - * pp Socket.list_ip_address + * pp Socket.ip_address_list * #=> [#, * #, * #, @@ -1441,7 +1441,7 @@ sockaddr_obj(struct sockaddr *addr) * */ static VALUE -socket_s_list_ip_address(VALUE self) +socket_s_ip_address_list(VALUE self) { #if defined(HAVE_GETIFADDRS) struct ifaddrs *ifp = NULL; @@ -1681,5 +1681,5 @@ Init_socket() rb_define_singleton_method(rb_cSocket, "unpack_sockaddr_un", sock_s_unpack_sockaddr_un, 1); #endif - rb_define_singleton_method(rb_cSocket, "list_ip_address", socket_s_list_ip_address, 0); + rb_define_singleton_method(rb_cSocket, "ip_address_list", socket_s_ip_address_list, 0); } diff --git a/test/socket/test_socket.rb b/test/socket/test_socket.rb index d3c3840464..cd19fdebf9 100644 --- a/test/socket/test_socket.rb +++ b/test/socket/test_socket.rb @@ -55,9 +55,9 @@ class TestSocket < Test::Unit::TestCase assert_raise(SocketError) { Socket.getnameinfo(["AF_UNIX", 80, "0.0.0.0"]) } end - def test_list_ip_address + def test_ip_address_list begin - list = Socket.list_ip_address + list = Socket.ip_address_list rescue NotImplementedError return end