On Wednesday, May 14, 2003, at 02:48 PM, Dave Thomas wrote:

> On my Mac OSX,
>
>    TCPSocket.new('localhost', 'echo')

> raises EINVAL:
>
> Errno::EINVAL: Invalid argument - "connect(2)"
>         from (irb):2:in `initialize'
>         from (irb):2:in `new'
>         from (irb):2
>
>
> This breaks ping.rb, which seems to assume it will be seeing 
> ECONNREFUSED. This means that pingecho('localhost') returns false on 
> my box.
>
> Is this expected behavior?

I think this is valid per default mac os x setup:

<497> telnet localhost echo
Trying ::1...
telnet: connect to address ::1: Connection refused
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host