8050798: New unchecked warning introduced in com.sun.jndi.ldap.Connection
authordarcy
Wed, 16 Jul 2014 17:45:13 -0700
changeset 25577 1d036fa8c9c4
parent 25576 d461312cb89f
child 25578 f9ecfa57b573
8050798: New unchecked warning introduced in com.sun.jndi.ldap.Connection Reviewed-by: lancea
jdk/src/share/classes/com/sun/jndi/ldap/Connection.java
--- a/jdk/src/share/classes/com/sun/jndi/ldap/Connection.java	Wed Jul 16 14:39:59 2014 -0700
+++ b/jdk/src/share/classes/com/sun/jndi/ldap/Connection.java	Wed Jul 16 17:45:13 2014 -0700
@@ -258,9 +258,9 @@
 
             // create the factory
 
+            @SuppressWarnings("unchecked")
             Class<? extends SocketFactory> socketFactoryClass =
-                    (Class<? extends SocketFactory>) Obj.helper.loadClass
-                    (socketFactory);
+                (Class<? extends SocketFactory>)Obj.helper.loadClass(socketFactory);
             Method getDefault =
                 socketFactoryClass.getMethod("getDefault", new Class<?>[]{});
             SocketFactory factory = (SocketFactory) getDefault.invoke(null, new Object[]{});