async-http 0.51.1 → 0.51.2

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
  SHA256:
3
- metadata.gz: 03ab7c81b4b33796381eb12f68eb13a3bcf90154ebc5a90b9647fa23e9d50164
4
- data.tar.gz: 581fc5c6a3171f5e1f5b08301d82b528379a4ef198d759e01d4588bdbc2b3a9e
3
+ metadata.gz: 5b03f19e4005697c43dc37437eeb829b72a8b88f89afe1b855c9d510ee6e7750
4
+ data.tar.gz: 46e4d1753c9f5bb1b9f712a3f1cda65bceaa9c71d2fc8cd8bb670b024efc9795
5
5
  SHA512:
6
- metadata.gz: f86b4e0480627ecf5cb4042ed36e8cf3759395a4de3ec441c306876300a6ad130657c9cf79da2c823df02bdde5137a1a75d03b0c4736c0953619e77dfc8c1553
7
- data.tar.gz: 43e9629f43b68b5d1077a8f23c0b1305dbd0dc2f91a458f8b814e2bf422e1870b77714a31c687979698ceff7f2fc34a504dd25cb34803cd735ebfd05aa9b4693
6
+ metadata.gz: c875c93bddde3ad8255a91e525d25c3a7555b63d4d37bebdee7b5ee60d5c9f08555589edf92dfe45c9d2a5205eaf8ee23ff348079e05cc4f99482deb62eae864
7
+ data.tar.gz: 124efb1c6b387160e68d58d592f6642a14087ed93b2e43a121d303db25d1d1e3544a0df3e85557518a517a79e520e2dcb706e015842be1cc995d239b38718bec
@@ -54,8 +54,11 @@ module Async
54
54
  end
55
55
 
56
56
  def close
57
- @clients.each_value(&:close)
57
+ # The order of operations here is to avoid a race condition between iterating over clients (#close may yield) and creating new clients.
58
+ clients = @clients.values
58
59
  @clients.clear
60
+
61
+ clients.each(&:close)
59
62
  end
60
63
 
61
64
  ::Protocol::HTTP::Methods.each do |name, verb|
@@ -22,6 +22,6 @@
22
22
 
23
23
  module Async
24
24
  module HTTP
25
- VERSION = "0.51.1"
25
+ VERSION = "0.51.2"
26
26
  end
27
27
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: async-http
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.51.1
4
+ version: 0.51.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-08 00:00:00.000000000 Z
11
+ date: 2020-04-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: async