summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDiego Algorta <diego@oboxodo.com>2009-08-14 19:59:39 -0300
committerAJ Christensen <aj@junglist.gen.nz>2009-10-02 12:37:07 +1300
commit6f2a3620474004ee3cfe4f476dda777aefd5add0 (patch)
tree2d90b40f0a45e7daaec87dd2574e116da37ff67c /lib
parentfb568e48719fbc22b5b47d2b9877742f28db71bb (diff)
downloadohai-6f2a3620474004ee3cfe4f476dda777aefd5add0.tar.gz
"LC_ALL" could be set to nil, in which case we also must ignore it.
Diffstat (limited to 'lib')
-rw-r--r--lib/ohai/mixin/command.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/ohai/mixin/command.rb b/lib/ohai/mixin/command.rb
index 696bbe28..33dff964 100644
--- a/lib/ohai/mixin/command.rb
+++ b/lib/ohai/mixin/command.rb
@@ -113,7 +113,8 @@ module Ohai
# Default on C locale so parsing commands output can be done
# independently of the node's default locale.
- unless args[:environment]["LC_ALL"]
+ # "LC_ALL" could be set to nil, in which case we also must ignore it.
+ unless args[:environment].has_key?("LC_ALL")
args[:environment]["LC_ALL"] = "C"
end