RFR(S): JDK-8173894: jib reports version "" in jdk10

Stefan Sarne stefan.sarne at oracle.com
Fri Feb 3 14:50:30 UTC 2017


Hi,

Please review and sponsor this small patch to jib profiles.
It makes sure version parsing handles 10.

Thanks,
Stefan

  - - -

# HG changeset patch
# User ssarne
# Date 1486133045 -3600
#      Fri Feb 03 15:44:05 2017 +0100
# Node ID b0a2d45408861586b361cf19d6a3522f05d27bd9
# Parent  d98052f2d47963a36e93f699a1cb85dc69e695be
JDK-8173894: jib reports version "" in jdk10
Summary: Update getVersion function, missing \ in regexp when stripping 
trailing zeros.
Reviewed-by:
Contributed-by: stefan.sarne at oracle.com

diff -r d98052f2d479 -r b0a2d4540886 common/conf/jib-profiles.js
--- a/common/conf/jib-profiles.js       Tue Jan 31 21:06:43 2017 -0500
+++ b/common/conf/jib-profiles.js       Fri Feb 03 15:44:05 2017 +0100
@@ -1067,7 +1067,7 @@
          + "." + (minor != null ? minor : 
version_numbers.get("DEFAULT_VERSION_MINOR"))
          + "." + (security != null ? security : 
version_numbers.get("DEFAULT_VERSION_SECURITY"))
          + "." + (patch != null ? patch : 
version_numbers.get("DEFAULT_VERSION_PATCH"));
-    while (version.match(".*\.0$")) {
+    while (version.match(".*\\.0$")) {
          version = version.substring(0, version.length - 2);
      }
      return version;




More information about the build-dev mailing list