lxc 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
data/lib/lxc/container.rb CHANGED
@@ -176,7 +176,7 @@ class LXC
176
176
  result = self.info("--state", *args).collect{ |str| str.scan(REGEX_STATE) }
177
177
  result.flatten!.compact!
178
178
 
179
- result.first.strip.downcase.to_sym
179
+ (result.first.strip.downcase.to_sym rescue :unknown)
180
180
  end
181
181
 
182
182
  # PID of the container
@@ -189,7 +189,7 @@ class LXC
189
189
  result = self.info("--pid", *args).collect{ |str| str.scan(REGEX_PID) }
190
190
  result.flatten!.compact!
191
191
 
192
- result.first.strip.to_i
192
+ (result.first.strip.to_i rescue -1)
193
193
  end
194
194
 
195
195
  # Does the container exist?
data/lib/lxc/version.rb CHANGED
@@ -2,7 +2,7 @@ class LXC
2
2
 
3
3
  unless const_defined?(:VERSION)
4
4
  # LXC Gem Version
5
- VERSION = "0.0.8"
5
+ VERSION = "0.0.9"
6
6
  end
7
7
 
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lxc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-04-25 00:00:00.000000000 Z
12
+ date: 2013-04-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: ztk
@@ -180,12 +180,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
180
180
  - - ! '>='
181
181
  - !ruby/object:Gem::Version
182
182
  version: '0'
183
+ segments:
184
+ - 0
185
+ hash: 1034151525174277004
183
186
  required_rubygems_version: !ruby/object:Gem::Requirement
184
187
  none: false
185
188
  requirements:
186
189
  - - ! '>='
187
190
  - !ruby/object:Gem::Version
188
191
  version: '0'
192
+ segments:
193
+ - 0
194
+ hash: 1034151525174277004
189
195
  requirements: []
190
196
  rubyforge_project:
191
197
  rubygems_version: 1.8.25