< prev index next >

src/jdk.jdi/share/classes/com/sun/tools/jdi/RawCommandLineLauncher.java

Print this page

        

@@ -51,21 +51,23 @@
 
     public RawCommandLineLauncher() {
         super();
 
         try {
-            Class<?> c = Class.forName("com.sun.tools.jdi.SharedMemoryTransportService");
-            transportService = (TransportService)c.newInstance();
+            @SuppressWarnings("deprecation")
+            Object o =
+                Class.forName("com.sun.tools.jdi.SharedMemoryTransportService").newInstance();
+            transportService = (TransportService)o;
             transport = new Transport() {
                 public String name() {
                     return "dt_shmem";
                 }
             };
-        } catch (ClassNotFoundException x) {
-        } catch (UnsatisfiedLinkError x) {
-        } catch (InstantiationException x) {
-        } catch (IllegalAccessException x) {
+        } catch (ClassNotFoundException |
+                 UnsatisfiedLinkError |
+                 InstantiationException |
+                 IllegalAccessException x) {
         };
 
         if (transportService == null) {
             transportService = new SocketTransportService();
             transport = new Transport() {
< prev index next >