src/jdk.naming.rmi/share/classes/com/sun/jndi/rmi/registry/RegistryContext.java

Print this page
rev 11093 : 8066642: Fix deprecation warnings in jdk.naming module
Reviewed-by: Ded Moroz

*** 351,361 **** /** * Wrap a RemoteException inside a NamingException. */ - @SuppressWarnings("deprecation") public static NamingException wrapRemoteException(RemoteException re) { NamingException ne; if (re instanceof ConnectException) { --- 351,360 ----
*** 363,374 **** } else if (re instanceof AccessException) { ne = new NoPermissionException(); } else if (re instanceof StubNotFoundException || ! re instanceof UnknownHostException || ! re instanceof SocketSecurityException) { ne = new ConfigurationException(); } else if (re instanceof ExportException || re instanceof ConnectIOException || re instanceof MarshalException || --- 362,372 ---- } else if (re instanceof AccessException) { ne = new NoPermissionException(); } else if (re instanceof StubNotFoundException || ! re instanceof UnknownHostException) { ne = new ConfigurationException(); } else if (re instanceof ExportException || re instanceof ConnectIOException || re instanceof MarshalException ||
*** 412,426 **** /** * Attempts to install a security manager if none is currently in * place. */ - @SuppressWarnings("deprecation") private static void installSecurityMgr() { try { ! System.setSecurityManager(new RMISecurityManager()); } catch (Exception e) { } } /** --- 410,423 ---- /** * Attempts to install a security manager if none is currently in * place. */ private static void installSecurityMgr() { try { ! System.setSecurityManager(new SecurityManager()); } catch (Exception e) { } } /**