8276561: URL$DefaultFactory::PREFIX should be static final

Reviewed-by: djelinski, jpai
This commit is contained in:
Michael McMahon 2022-07-21 11:03:48 +00:00
parent 52cc6cd063
commit 799a2c844d

View File

@ -1243,7 +1243,7 @@ public final class URL implements java.io.Serializable {
private static final URLStreamHandlerFactory defaultFactory = new DefaultFactory();
private static class DefaultFactory implements URLStreamHandlerFactory {
private static String PREFIX = "sun.net.www.protocol.";
private static final String PREFIX = "sun.net.www.protocol.";
public URLStreamHandler createURLStreamHandler(String protocol) {
// Avoid using reflection during bootstrap