changeset 31184:1ed0333a7723

8060103: CheckBlacklistedCerts.java thinks its openjdk build Reviewed-by: weijun
author rhalade
date Thu, 18 Jun 2015 11:16:01 +0800
parents eb0ffbecb4ba
children d3d7f5a45a5c
files jdk/test/lib/security/CheckBlacklistedCerts.java
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/jdk/test/lib/security/CheckBlacklistedCerts.java	Thu Nov 20 17:52:18 2014 +0800
+++ b/jdk/test/lib/security/CheckBlacklistedCerts.java	Thu Jun 18 11:16:01 2015 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -69,7 +69,9 @@
         };
 
         // Is this an OPENJDK build?
-        if (!new File(home, "lib/security/local_policy.jar").exists()) {
+        String prop = System.getProperty("java.runtime.name");
+        if (prop != null && prop.startsWith("OpenJDK")) {
+            System.out.println("This is a OpenJDK build.");
             blacklists = Arrays.copyOf(blacklists, 1);
         }