summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkaustubh-d <kaustubh@clogeny.com>2014-09-29 10:23:48 -0700
committerkaustubh-d <kaustubh@clogeny.com>2014-09-29 10:23:48 -0700
commitb126202631ea05fcc403116f2f62201b775b04f5 (patch)
tree1901a5b42a61da52e7f0c85461e8c5cc63fe7b5b
parent35dc3d5010dc6392f8fbb7f389534e47c0e0427a (diff)
downloadohai-b126202631ea05fcc403116f2f62201b775b04f5.tar.gz
aix - fix regex to get java version
-rw-r--r--lib/ohai/plugins/java.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ohai/plugins/java.rb b/lib/ohai/plugins/java.rb
index 9f71eb7f..8e896488 100644
--- a/lib/ohai/plugins/java.rb
+++ b/lib/ohai/plugins/java.rb
@@ -28,7 +28,7 @@ Ohai.plugin(:Java) do
case line
when /java version \"([0-9\.\_]+)\"/
java[:version] = $1
- when /^(.+Runtime Environment.*) \((build )?(.+)\)$/
+ when /^(.+Runtime Environment.*) \((build)\s*(.+)\)$/
java[:runtime] = { "name" => $1, "build" => $3 }
when /^(.+ (Client|Server) VM) \(build (.+)\)$/
java[:hotspot] = { "name" => $1, "build" => $3 }