Merge
This commit is contained in:
commit
4f4ddb6e5f
@ -28,6 +28,7 @@ PACKAGE = sun.net
|
|||||||
PRODUCT = sun
|
PRODUCT = sun
|
||||||
SUBDIRS_MAKEFLAGS += JAVAC_MAX_WARNINGS=true
|
SUBDIRS_MAKEFLAGS += JAVAC_MAX_WARNINGS=true
|
||||||
SUBDIRS_MAKEFLAGS += JAVAC_WARNINGS_FATAL=true
|
SUBDIRS_MAKEFLAGS += JAVAC_WARNINGS_FATAL=true
|
||||||
|
SUBDIRS_MAKEFLAGS += JAVAC_LINT_OPTIONS=-Xlint:all,-deprecation,-path
|
||||||
include $(BUILDDIR)/common/Defs.gmk
|
include $(BUILDDIR)/common/Defs.gmk
|
||||||
|
|
||||||
SUBDIRS = others spi
|
SUBDIRS = others spi
|
||||||
|
@ -876,10 +876,12 @@ class InetAddress implements java.io.Serializable {
|
|||||||
nameService = java.security.AccessController.doPrivileged(
|
nameService = java.security.AccessController.doPrivileged(
|
||||||
new java.security.PrivilegedExceptionAction<NameService>() {
|
new java.security.PrivilegedExceptionAction<NameService>() {
|
||||||
public NameService run() {
|
public NameService run() {
|
||||||
Iterator itr = Service.providers(NameServiceDescriptor.class);
|
// sun.misc.Service.providers returns a raw Iterator
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
|
Iterator<NameServiceDescriptor> itr =
|
||||||
|
Service.providers(NameServiceDescriptor.class);
|
||||||
while (itr.hasNext()) {
|
while (itr.hasNext()) {
|
||||||
NameServiceDescriptor nsd
|
NameServiceDescriptor nsd = itr.next();
|
||||||
= (NameServiceDescriptor)itr.next();
|
|
||||||
if (providerName.
|
if (providerName.
|
||||||
equalsIgnoreCase(nsd.getType()+","
|
equalsIgnoreCase(nsd.getType()+","
|
||||||
+nsd.getProviderName())) {
|
+nsd.getProviderName())) {
|
||||||
|
@ -267,10 +267,9 @@ class ServerSocket implements java.io.Closeable {
|
|||||||
AccessController.doPrivileged(
|
AccessController.doPrivileged(
|
||||||
new PrivilegedExceptionAction<Void>() {
|
new PrivilegedExceptionAction<Void>() {
|
||||||
public Void run() throws NoSuchMethodException {
|
public Void run() throws NoSuchMethodException {
|
||||||
Class[] cl = new Class[2];
|
impl.getClass().getDeclaredMethod("connect",
|
||||||
cl[0] = SocketAddress.class;
|
SocketAddress.class,
|
||||||
cl[1] = Integer.TYPE;
|
int.class);
|
||||||
impl.getClass().getDeclaredMethod("connect", cl);
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -435,7 +435,7 @@ public abstract class Charset
|
|||||||
AccessController.doPrivileged(new PrivilegedAction<Object>() {
|
AccessController.doPrivileged(new PrivilegedAction<Object>() {
|
||||||
public Object run() {
|
public Object run() {
|
||||||
try {
|
try {
|
||||||
Class epc
|
Class<?> epc
|
||||||
= Class.forName("sun.nio.cs.ext.ExtendedCharsets");
|
= Class.forName("sun.nio.cs.ext.ExtendedCharsets");
|
||||||
extendedProvider = (CharsetProvider)epc.newInstance();
|
extendedProvider = (CharsetProvider)epc.newInstance();
|
||||||
} catch (ClassNotFoundException x) {
|
} catch (ClassNotFoundException x) {
|
||||||
|
@ -814,7 +814,7 @@ public final class Security {
|
|||||||
public Void run() {
|
public Void run() {
|
||||||
try {
|
try {
|
||||||
/* Get the class via the bootstrap class loader. */
|
/* Get the class via the bootstrap class loader. */
|
||||||
Class cl = Class.forName(
|
Class<?> cl = Class.forName(
|
||||||
"java.lang.SecurityManager", false, null);
|
"java.lang.SecurityManager", false, null);
|
||||||
Field f = null;
|
Field f = null;
|
||||||
boolean accessible = false;
|
boolean accessible = false;
|
||||||
|
@ -443,7 +443,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#word">word breaks</a>
|
* for <a href="BreakIterator.html#word">word breaks</a>
|
||||||
* for the {@linkplain Locale#getDefault() default locale}.
|
* for the {@linkplain Locale#getDefault() default locale}.
|
||||||
* @return A break iterator for word breaks
|
* @return A break iterator for word breaks
|
||||||
*/
|
*/
|
||||||
@ -454,7 +454,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#word">word breaks</a>
|
* for <a href="BreakIterator.html#word">word breaks</a>
|
||||||
* for the given locale.
|
* for the given locale.
|
||||||
* @param locale the desired locale
|
* @param locale the desired locale
|
||||||
* @return A break iterator for word breaks
|
* @return A break iterator for word breaks
|
||||||
@ -470,7 +470,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#line">line breaks</a>
|
* for <a href="BreakIterator.html#line">line breaks</a>
|
||||||
* for the {@linkplain Locale#getDefault() default locale}.
|
* for the {@linkplain Locale#getDefault() default locale}.
|
||||||
* @return A break iterator for line breaks
|
* @return A break iterator for line breaks
|
||||||
*/
|
*/
|
||||||
@ -481,7 +481,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#line">line breaks</a>
|
* for <a href="BreakIterator.html#line">line breaks</a>
|
||||||
* for the given locale.
|
* for the given locale.
|
||||||
* @param locale the desired locale
|
* @param locale the desired locale
|
||||||
* @return A break iterator for line breaks
|
* @return A break iterator for line breaks
|
||||||
@ -497,7 +497,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#character">character breaks</a>
|
* for <a href="BreakIterator.html#character">character breaks</a>
|
||||||
* for the {@linkplain Locale#getDefault() default locale}.
|
* for the {@linkplain Locale#getDefault() default locale}.
|
||||||
* @return A break iterator for character breaks
|
* @return A break iterator for character breaks
|
||||||
*/
|
*/
|
||||||
@ -508,7 +508,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#character">character breaks</a>
|
* for <a href="BreakIterator.html#character">character breaks</a>
|
||||||
* for the given locale.
|
* for the given locale.
|
||||||
* @param locale the desired locale
|
* @param locale the desired locale
|
||||||
* @return A break iterator for character breaks
|
* @return A break iterator for character breaks
|
||||||
@ -524,7 +524,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#sentence">sentence breaks</a>
|
* for <a href="BreakIterator.html#sentence">sentence breaks</a>
|
||||||
* for the {@linkplain Locale#getDefault() default locale}.
|
* for the {@linkplain Locale#getDefault() default locale}.
|
||||||
* @return A break iterator for sentence breaks
|
* @return A break iterator for sentence breaks
|
||||||
*/
|
*/
|
||||||
@ -535,7 +535,7 @@ public abstract class BreakIterator implements Cloneable
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a new <code>BreakIterator</code> instance
|
* Returns a new <code>BreakIterator</code> instance
|
||||||
* for <a href="#sentence">sentence breaks</a>
|
* for <a href="BreakIterator.html#sentence">sentence breaks</a>
|
||||||
* for the given locale.
|
* for the given locale.
|
||||||
* @param locale the desired locale
|
* @param locale the desired locale
|
||||||
* @return A break iterator for sentence breaks
|
* @return A break iterator for sentence breaks
|
||||||
|
@ -363,10 +363,10 @@ class Util {
|
|||||||
try {
|
try {
|
||||||
Class<?> cl = Class.forName("java.nio.DirectByteBuffer");
|
Class<?> cl = Class.forName("java.nio.DirectByteBuffer");
|
||||||
Constructor<?> ctor = cl.getDeclaredConstructor(
|
Constructor<?> ctor = cl.getDeclaredConstructor(
|
||||||
new Class[] { int.class,
|
new Class<?>[] { int.class,
|
||||||
long.class,
|
long.class,
|
||||||
FileDescriptor.class,
|
FileDescriptor.class,
|
||||||
Runnable.class });
|
Runnable.class });
|
||||||
ctor.setAccessible(true);
|
ctor.setAccessible(true);
|
||||||
directByteBufferConstructor = ctor;
|
directByteBufferConstructor = ctor;
|
||||||
} catch (ClassNotFoundException |
|
} catch (ClassNotFoundException |
|
||||||
@ -408,10 +408,10 @@ class Util {
|
|||||||
try {
|
try {
|
||||||
Class<?> cl = Class.forName("java.nio.DirectByteBufferR");
|
Class<?> cl = Class.forName("java.nio.DirectByteBufferR");
|
||||||
Constructor<?> ctor = cl.getDeclaredConstructor(
|
Constructor<?> ctor = cl.getDeclaredConstructor(
|
||||||
new Class[] { int.class,
|
new Class<?>[] { int.class,
|
||||||
long.class,
|
long.class,
|
||||||
FileDescriptor.class,
|
FileDescriptor.class,
|
||||||
Runnable.class });
|
Runnable.class });
|
||||||
ctor.setAccessible(true);
|
ctor.setAccessible(true);
|
||||||
directByteBufferRConstructor = ctor;
|
directByteBufferRConstructor = ctor;
|
||||||
} catch (ClassNotFoundException |
|
} catch (ClassNotFoundException |
|
||||||
|
Loading…
x
Reference in New Issue
Block a user