From d3571832fcd12751e940550cc3c3c1f6cd02057a Mon Sep 17 00:00:00 2001 From: Rajan Halade Date: Thu, 18 Jun 2015 11:16:01 +0800 Subject: [PATCH] 8060103: CheckBlacklistedCerts.java thinks its openjdk build Reviewed-by: weijun --- jdk/test/lib/security/CheckBlacklistedCerts.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/jdk/test/lib/security/CheckBlacklistedCerts.java b/jdk/test/lib/security/CheckBlacklistedCerts.java index a281a0460d8..bd1cf890275 100644 --- a/jdk/test/lib/security/CheckBlacklistedCerts.java +++ b/jdk/test/lib/security/CheckBlacklistedCerts.java @@ -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 @@ public class CheckBlacklistedCerts { }; // 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); }