java/180526: icedtea-web java plugin doesn't work with openjdk7.25

DMK dmk at ncf.ca
Sat Jul 13 01:30:00 UTC 2013


>Number:         180526
>Category:       java
>Synopsis:       icedtea-web java plugin doesn't work with openjdk7.25
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-java
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jul 13 01:30:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     DMK
>Release:        9.1-RELEASE
>Organization:
>Environment:
FreeBSD chiron.lan 9.1-RELEASE FreeBSD 9.1-RELEASE #8: Sun Jan 20 18:27:16 EST 2013     root at chiron.lan:/usr/obj/usr/src/sys/CHIRON  i386

>Description:
As reported in http://blog.fuseyism.com/index.php/2013/06/19/imminent-icedtea-web-breakage/ the recent security update to openjdk broke the icedtea-web java plugin. The blog reports a new release of icedtea-web "soon" but details are scarce.
>How-To-Repeat:
Try any java applet in firefox when it has icedtea-web installed
>Fix:
The blog linked to a fix; I've take a few minutes to get the patches working with the icedtea-web port. I've tried it out, it seems to work perfectly.

The file I've attached is a shar file.

Patch attached with submission follows:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	patch-ChangeLog
#	patch-netx_net_sourceforge_jnlp_runtime_Boot.java
#	patch-netx_net_sourceforge_jnlp_runtime_JNLPRuntime.java
#	patch-plugin_icedteanp_java_sun_applet_PluginMain.java
#
echo x - patch-ChangeLog
sed 's/^X//' >patch-ChangeLog << 'ab9e15ed5cc7bd48445f9a38c9a828cd'
Xdiff -r fa6a80c73e0d -r 2469bedc6d63 ChangeLog
X--- ChangeLog	Tue Jun 18 15:57:01 2013 -0400
X+++ ChangeLog	Thu Jun 20 15:20:57 2013 +0200
X@@ -1,3 +1,13 @@
X+2013-06-20  Jiri Vanek <jvanek at redhat.com>
X+
X+	Made it work with OpenJDK build 25
X+	* netx/net/sourceforge/jnlp/runtime/Boot.java: (main) 
X+	Application context created as soon as possible
X+	* plugin/icedteanp/java/sun/applet/PluginMain.java:(main)
X+	Application context created as soon as possible
X+	* netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Do not consume
X+	exception after setLookAndFeel.
X+
ab9e15ed5cc7bd48445f9a38c9a828cd
echo x - patch-netx_net_sourceforge_jnlp_runtime_Boot.java
sed 's/^X//' >patch-netx_net_sourceforge_jnlp_runtime_Boot.java << 'c08d7203e2e5ef9942a8a0c2c8de19e6'
Xdiff -r fa6a80c73e0d -r 2469bedc6d63 netx/net/sourceforge/jnlp/runtime/Boot.java
X--- netx/net/sourceforge/jnlp/runtime/Boot.java.orig	Tue Jun 18 15:57:01 2013 -0400
X+++ netx/net/sourceforge/jnlp/runtime/Boot.java	Thu Jun 20 15:20:57 2013 +0200
X@@ -35,6 +35,8 @@
X import net.sourceforge.jnlp.cache.UpdatePolicy;
X import net.sourceforge.jnlp.security.viewer.CertificateViewer;
X import net.sourceforge.jnlp.services.ServiceUtil;
X+import sun.awt.AppContext;
X+import sun.awt.SunToolkit;
X 
X /**
X  * This is the main entry point for the JNLP client.  The main
X@@ -113,6 +115,9 @@
X      * Launch the JNLP file specified by the command-line arguments.
X      */
X     public static void main(String[] argsIn) {
X+        if (AppContext.getAppContext() == null) {
X+            SunToolkit.createNewAppContext();
X+        }
X         args = argsIn;
X 
X         if (null != getOption("-viewer")) {
c08d7203e2e5ef9942a8a0c2c8de19e6
echo x - patch-netx_net_sourceforge_jnlp_runtime_JNLPRuntime.java
sed 's/^X//' >patch-netx_net_sourceforge_jnlp_runtime_JNLPRuntime.java << '4a3a7159e34dc7f2497833127f10af3b'
Xdiff -r fa6a80c73e0d -r 2469bedc6d63 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java
X--- netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java.orig	Tue Jun 18 15:57:01 2013 -0400
X+++ netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java	Thu Jun 20 15:20:57 2013 +0200
X@@ -234,7 +234,7 @@
X         try {
X             UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
X         } catch (Exception e) {
X-            // ignore it
X+            e.printStackTrace();
X         }
X 
X         doMainAppContextHacks();
4a3a7159e34dc7f2497833127f10af3b
echo x - patch-plugin_icedteanp_java_sun_applet_PluginMain.java
sed 's/^X//' >patch-plugin_icedteanp_java_sun_applet_PluginMain.java << '7679251cf8f8e34267a2332306322834'
Xdiff -r fa6a80c73e0d -r 2469bedc6d63 plugin/icedteanp/java/sun/applet/PluginMain.java
X--- plugin/icedteanp/java/sun/applet/PluginMain.java.orig	Tue Jun 18 15:57:01 2013 -0400
X+++ plugin/icedteanp/java/sun/applet/PluginMain.java	Thu Jun 20 15:20:57 2013 +0200
X@@ -72,6 +72,8 @@
X import java.net.ProxySelector;
X import java.util.Enumeration;
X import java.util.Properties;
X+import sun.awt.AppContext;
X+import sun.awt.SunToolkit;
X 
X import net.sourceforge.jnlp.config.DeploymentConfiguration;
X import net.sourceforge.jnlp.runtime.JNLPRuntime;
X@@ -94,6 +96,9 @@
X      */
X     public static void main(String args[])
X             throws IOException {
X+        if (AppContext.getAppContext() == null) {
X+            SunToolkit.createNewAppContext();
X+        }
X         if (args.length != 2 || !(new File(args[0]).exists()) || !(new File(args[1]).exists())) {
X             System.err.println("Invalid pipe names provided. Refusing to proceed.");
X             System.exit(1);
X
7679251cf8f8e34267a2332306322834
exit



>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-java mailing list