--- old/src/java.desktop/share/classes/javax/swing/text/html/ObjectView.java 2016-11-07 10:47:24.407786425 -0800 +++ new/src/java.desktop/share/classes/javax/swing/text/html/ObjectView.java 2016-11-07 10:47:24.259786426 -0800 @@ -46,7 +46,7 @@ *
* If the class can successfully be loaded, an attempt will
* be made to create an instance of it by calling
- * Class.newInstance
. An attempt will be made
+ * Class.getDeclaredConstructor().newInstance
. An attempt will be made
* to narrow the instance to type java.awt.Component
* to display the object.
*
@@ -92,7 +92,7 @@ ReflectUtil.checkPackageAccess(classname); Class> c = Class.forName(classname, true,Thread.currentThread(). getContextClassLoader()); - Object o = c.newInstance(); + Object o = c.getDeclaredConstructor().newInstance(); if (o instanceof Component) { Component comp = (Component) o; setParameters(comp, attr);