diff --git a/ChangeLog b/ChangeLog index d12f5e36b7..a1d507ef39 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Sun Jul 19 10:54:56 2009 Tanaka Akira + + * ext/socket/lib/socket.rb (Socket.accept_loop): rescue + IO::WaitReadable instead of Errno::EWOULDBLOCK. + (Socket.udp_server_loop_on): ditto. + Sat Jul 18 23:44:59 2009 NARUSE, Yui * re.c (reg_enc_error): use rb_enc_get to get the encoding of diff --git a/ext/socket/lib/socket.rb b/ext/socket/lib/socket.rb index 8d417487ec..1f155e7813 100644 --- a/ext/socket/lib/socket.rb +++ b/ext/socket/lib/socket.rb @@ -404,7 +404,7 @@ class Socket readable.each {|r| begin sock, addr = r.accept_nonblock - rescue Errno::EWOULDBLOCK + rescue IO::WaitReadable next end yield sock, addr @@ -567,7 +567,7 @@ class Socket readable.each {|r| begin msg, sender_addrinfo, rflags, *controls = r.recvmsg_nonblock - rescue Errno::EWOULDBLOCK + rescue IO::WaitReadable next end ai = r.local_address