rb-inotify 0.9.3 → 0.9.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 3ba75901bcb7b3a8d2b5819396e51b38c97074a0
4
+ data.tar.gz: 485b593853e4efdb9268a27856e3f1d966e41bfc
5
+ SHA512:
6
+ metadata.gz: fa9e4f59667cf3b9670a90bb05f458d211f7273bbd67850f750be1a1a050309c15f8be55297199f5cfac16ae4e0a7d972ffb6e605125ecb8c3f1d5e617029c3c
7
+ data.tar.gz: 510a6b239de8612d48427c303867e1c66ed8e1e9d5b09b861807efae7b16e4c84b91b04b24b17ab74b35408a3ceeedd3af8e1b553b64bf9d2602a5ebe64710d6
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.9.3
1
+ 0.9.4
data/lib/rb-inotify.rb CHANGED
@@ -13,5 +13,5 @@ module INotify
13
13
  # An array containing the version number of rb-inotify.
14
14
  # The numbers in the array are the major, minor, and patch versions,
15
15
  # respectively.
16
- VERSION = [0, 9, 3]
16
+ VERSION = [0, 9, 4]
17
17
  end
@@ -242,7 +242,10 @@ module INotify
242
242
  #
243
243
  # @raise [SystemCallError] if closing the underlying file descriptor fails.
244
244
  def close
245
- return if Native.close(@fd) == 0
245
+ if Native.close(@fd) == 0
246
+ @watchers.clear
247
+ return
248
+ end
246
249
 
247
250
  raise SystemCallError.new("Failed to properly close inotify socket" +
248
251
  case FFI.errno
@@ -45,8 +45,13 @@ module INotify
45
45
  #
46
46
  # @raise [SystemCallError] if the watch fails to be disabled for some reason
47
47
  def close
48
- return if Native.inotify_rm_watch(@notifier.fd, @id) == 0
49
- raise SystemCallError.new("Failed to stop watching #{path.inspect}", FFI.errno)
48
+ if Native.inotify_rm_watch(@notifier.fd, @id) == 0
49
+ @notifier.watchers.delete(@id)
50
+ return
51
+ end
52
+
53
+ raise SystemCallError.new("Failed to stop watching #{path.inspect}",
54
+ FFI.errno)
50
55
  end
51
56
 
52
57
  # Creates a new {Watcher}.
data/rb-inotify.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "rb-inotify"
8
- s.version = "0.9.3"
8
+ s.version = "0.9.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Nathan Weizenbaum"]
12
- s.date = "2013-12-14"
12
+ s.date = "2014-04-25"
13
13
  s.description = "A Ruby wrapper for Linux's inotify, using FFI"
14
14
  s.email = "nex342@gmail.com"
15
15
  s.extra_rdoc_files = [
@@ -31,11 +31,11 @@ Gem::Specification.new do |s|
31
31
  ]
32
32
  s.homepage = "http://github.com/nex3/rb-inotify"
33
33
  s.require_paths = ["lib"]
34
- s.rubygems_version = "1.8.24"
34
+ s.rubygems_version = "2.0.3"
35
35
  s.summary = "A Ruby wrapper for Linux's inotify, using FFI"
36
36
 
37
37
  if s.respond_to? :specification_version then
38
- s.specification_version = 3
38
+ s.specification_version = 4
39
39
 
40
40
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
41
41
  s.add_runtime_dependency(%q<ffi>, [">= 0.5.0"])
metadata CHANGED
@@ -1,46 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rb-inotify
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.3
5
- prerelease:
4
+ version: 0.9.4
6
5
  platform: ruby
7
6
  authors:
8
7
  - Nathan Weizenbaum
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-12-14 00:00:00.000000000 Z
11
+ date: 2014-04-25 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: ffi
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - '>='
20
18
  - !ruby/object:Gem::Version
21
19
  version: 0.5.0
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ! '>='
24
+ - - '>='
28
25
  - !ruby/object:Gem::Version
29
26
  version: 0.5.0
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: yard
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ! '>='
31
+ - - '>='
36
32
  - !ruby/object:Gem::Version
37
33
  version: 0.4.0
38
34
  type: :development
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ! '>='
38
+ - - '>='
44
39
  - !ruby/object:Gem::Version
45
40
  version: 0.4.0
46
41
  description: A Ruby wrapper for Linux's inotify, using FFI
@@ -64,26 +59,25 @@ files:
64
59
  - rb-inotify.gemspec
65
60
  homepage: http://github.com/nex3/rb-inotify
66
61
  licenses: []
62
+ metadata: {}
67
63
  post_install_message:
68
64
  rdoc_options: []
69
65
  require_paths:
70
66
  - lib
71
67
  required_ruby_version: !ruby/object:Gem::Requirement
72
- none: false
73
68
  requirements:
74
- - - ! '>='
69
+ - - '>='
75
70
  - !ruby/object:Gem::Version
76
71
  version: '0'
77
72
  required_rubygems_version: !ruby/object:Gem::Requirement
78
- none: false
79
73
  requirements:
80
- - - ! '>='
74
+ - - '>='
81
75
  - !ruby/object:Gem::Version
82
76
  version: '0'
83
77
  requirements: []
84
78
  rubyforge_project:
85
- rubygems_version: 1.8.24
79
+ rubygems_version: 2.0.3
86
80
  signing_key:
87
- specification_version: 3
81
+ specification_version: 4
88
82
  summary: A Ruby wrapper for Linux's inotify, using FFI
89
83
  test_files: []