Advertisement
ChickenNinja

ECONNREFUSED

Jun 19th, 2013
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.15 KB | None | 0 0
  1. begin
  2.     for ping in $ip
  3.         tcp  = Net::HTTP.get_response(URI.parse(ping))
  4.         puts "#{tcp.code} #{ping}"
  5.     end
  6. rescue Errno::ECONNREFUSED
  7.     next
  8. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement