< prev index next >

src/java.desktop/share/classes/java/beans/Beans.java

Print this page

        

@@ -228,11 +228,13 @@
             /*
              * Try to instantiate the class.
              */
 
             try {
-                result = cl.newInstance();
+                @SuppressWarnings("deprecation")
+                Object tmp = cl.newInstance();
+                result = tmp;
             } catch (Exception ex) {
                 // We have to remap the exception to one in our signature.
                 // But we pass extra information in the detail message.
                 throw new ClassNotFoundException("" + cl + " : " + ex, ex);
             }
< prev index next >