Module SporkDebugger::NetworkHelpers
In: lib/spork/ext/ruby-debug.rb

Methods

find_port  

Public Instance methods

[Source]

# File lib/spork/ext/ruby-debug.rb, line 30
    def find_port(starting_with)
      port = starting_with
      begin
        server = TCPServer.new(HOST, port)
        server.close
      rescue Errno::EADDRINUSE
        port += 1
        retry
      end

      port
    end

[Validate]