em-nodes 0.5 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f1363157af5191aec0b3766f90bbea6f6f796774
4
- data.tar.gz: c62062bed18a240bedb582f7181496b7801d278c
3
+ metadata.gz: 63bf7a640509b5d505dab58cd5e3b05a876cf3fe
4
+ data.tar.gz: a661ef9b96da2ebffe719f4d0b119854d200bcad
5
5
  SHA512:
6
- metadata.gz: de60f8921cce94868c95f6e9206dad695473f6d511f7e185d03ec401cb63fd39823e9edcdd332f3f77e3ae0cde15caad567ca08f02a5c6e54a7b8e274678d54f
7
- data.tar.gz: 109ee1213f2002c4fe8fa21839386c971e7e4743c9294cd68525682329786f86b7a76370f2d450099a3c9db2898fa5591ca78a8ec17f9f8d29bbce9bf8d50c93
6
+ metadata.gz: d05d3cd9556e979bccc301b61d4096c9fcd24a26699b8af2e7f21c3f501ace11b2356a49c698e43c33c10bdd296cddb7e545171bcb3e3e70df814b06f92814b4
7
+ data.tar.gz: 28c387f119f1da47370cabcf64904b9f4824a507e7244a3d969340dd44169859dde9d9d64c0dbdef887a07fc3ab930079bb8ad5e13b2a4966fb23208db20dde7
@@ -37,11 +37,16 @@ class EM::Nodes::Server < EM::Connection
37
37
  self.comm_inactivity_timeout = inactivity_timeout if EM.reactor_running?
38
38
 
39
39
  port, host = Socket.unpack_sockaddr_in(get_peername) rescue []
40
- host = Socket.unpack_sockaddr_un(get_sockname) unless host
40
+
41
+ unless host
42
+ host = Socket.unpack_sockaddr_un(get_sockname) rescue nil
43
+ end
44
+
41
45
  unless accept?(host, port)
42
46
  unbind
43
47
  return
44
48
  end
49
+
45
50
  self.data.host = host
46
51
  self.data.port = port
47
52
 
@@ -6,7 +6,7 @@ class EM::Nodes::Server
6
6
 
7
7
  module ClassMethods
8
8
  def ready_clients
9
- clients.select{ |cl| cl.data.ready }
9
+ alive_clients.select{ |cl| cl.data.ready }
10
10
  end
11
11
  end
12
12
 
@@ -2,5 +2,5 @@ module EventMachine
2
2
  end
3
3
 
4
4
  module EventMachine::Nodes
5
- VERSION = "0.5"
5
+ VERSION = "0.5.1"
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: em-nodes
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.5'
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - "'Konstantin Makarchev'"