summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/ohai/plugins/java.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/ohai/plugins/java.rb b/lib/ohai/plugins/java.rb
index 67310bfd..d5bbd7e2 100644
--- a/lib/ohai/plugins/java.rb
+++ b/lib/ohai/plugins/java.rb
@@ -6,9 +6,9 @@
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
-#
+#
# http://www.apache.org/licenses/LICENSE-2.0
-#
+#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -22,8 +22,8 @@ require_plugin "languages"
java = Mash.new
status, stdout, stderr = nil
-if RUBY_PLATFORM.downcase.include?("darwin")
- if system("/usr/libexec/java_home 2>&1 >/dev/null")
+if RUBY_PLATFORM.downcase.include?("darwin")
+ if system("/usr/libexec/java_home >/dev/null 2>&1")
status, stdout, stderr = run_command(:no_status_check => true, :command => "java -version")
end
else