fizx-proxymachine 1.5.1 → 1.5.2
Sign up to get free protection for your applications and to get access to all the features.
data/fizx-proxymachine.gemspec
CHANGED
@@ -13,7 +13,7 @@ Gem::Specification.new do |s|
|
|
13
13
|
## If your rubyforge_project name is different, then edit it and comment out
|
14
14
|
## the sub! line in the Rakefile
|
15
15
|
s.name = 'fizx-proxymachine'
|
16
|
-
s.version = '1.5.
|
16
|
+
s.version = '1.5.2'
|
17
17
|
s.date = '2011-05-07'
|
18
18
|
s.rubyforge_project = 'fizx-proxymachine'
|
19
19
|
|
data/lib/proxymachine.rb
CHANGED
@@ -76,7 +76,7 @@ class ProxyMachine
|
|
76
76
|
def connect_to_server
|
77
77
|
fail "connect_server called without remote established" if @remote.nil?
|
78
78
|
host, port = @remote
|
79
|
-
$logger.info "Establishing new connection with #{host}:#{port}"
|
79
|
+
$logger.info "Establishing new connection with #{host}:#{port} OHAI"
|
80
80
|
cb = @commands[:callback]
|
81
81
|
klass = cb ? CallbackServerConnection : ServerConnection
|
82
82
|
@server_side = klass.request(host, port, self)
|
@@ -107,7 +107,7 @@ class ProxyMachine
|
|
107
107
|
$logger.error "Connection with #{@remote.join(':')} was terminated prematurely."
|
108
108
|
close_connection
|
109
109
|
(@connect_error_callback || ProxyMachine.connect_error_callback).call(@remote.join(':'))
|
110
|
-
elsif @tries <
|
110
|
+
elsif @tries < 2
|
111
111
|
@tries += 1
|
112
112
|
$logger.warn "Retrying connection with #{@remote.join(':')} (##{@tries})"
|
113
113
|
EM.add_timer(0.1) { connect_to_server }
|