futuroscope 0.0.6 → 0.0.7

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: e165b095edd6b4a24e0d696a2de6d19fbbb32b76
4
- data.tar.gz: 30b612ac0946a96b7d4016e8f66b307f45d77482
3
+ metadata.gz: c35a579ddfa81bd3d51a36dc93a4f774e676949c
4
+ data.tar.gz: 39328f8e0892c81da476a3566d9ab7d4194a72fc
5
5
  SHA512:
6
- metadata.gz: bb92a560f8cf1c17eb6c6251d9258bb17832c2aef483337450d08968490d8b508819a3436d108d50f4ac6875223af0a385f732d7b1c743b85fbf3de45677c2c0
7
- data.tar.gz: 772f23f61ba3576af774239147047e7b0e4a5d15c2eb803ae7b71b10fe9a1b17d27c0990b5b5faa8ec56796b0e5b9b8222af59c556d926e546fd476643431e3c
6
+ metadata.gz: 5bb7cc63fe178d5442d6b164ff2c54bc6dd4f35f77870852e5e2e327acdec4587c5dc19fb9de3c7ecb715507f9813c91644a6255c7a73b3ab2a58e4a89301031
7
+ data.tar.gz: 677d8995bfccb00a705fff0574cc22d50c3ecc1190e856ff9690e3e7aebb467cd022451d2a0f5b4ebd81bc32d2ca5ff95a7772e03219bc2f8fc85c5c4c08a429
@@ -36,7 +36,9 @@ module Futuroscope
36
36
  #
37
37
  # Returns a Future
38
38
  def pop
39
- return nil if @queue.empty? && more_workers_than_needed?
39
+ @mutex.synchronize do
40
+ return nil if @queue.empty? && more_workers_than_needed?
41
+ end
40
42
  return @queue.pop
41
43
  end
42
44
 
@@ -1,3 +1,3 @@
1
1
  module Futuroscope
2
- VERSION = "0.0.6"
2
+ VERSION = "0.0.7"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: futuroscope
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy