lib/knj/autoload/ping.rb in knjrbfw-0.0.8 vs lib/knj/autoload/ping.rb in knjrbfw-0.0.9

- old
+ new

@@ -42,11 +42,11 @@ # Ping.pingecho "google.com", 10, 80 # def pingecho(host, timeout=5, service="echo") begin timeout(timeout) do - s = TCPSocket.new(host, service) - s.close + s = TCPSocket.new(host, service) + s.close end rescue Errno::ECONNREFUSED return true rescue Timeout::Error, StandardError return false