changeset 2663:066d3181805f

Update Zero to HotSpot from imminent 2.1.9 release. 2013-06-28 Andrew John Hughes <gnu.andrew@member.fsf.org> * NEWS: Mention that 8001330 is not in Zero. * hotspot.map: Update Zero to 2.1.9. * patches/boot/ecj-diamond.patch, * patches/boot/ecj-multicatch.patch, * patches/boot/ecj-stringswitch.patch: Add new cases.
author Andrew John Hughes <gnu_andrew@member.fsf.org>
date Fri, 28 Jun 2013 07:20:34 +0100
parents 26e811fe4d45
children ee8144fe33e6
files ChangeLog NEWS hotspot.map patches/boot/ecj-diamond.patch patches/boot/ecj-multicatch.patch patches/boot/ecj-stringswitch.patch
diffstat 6 files changed, 136 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Tue Jun 25 23:25:25 2013 -0500
+++ b/ChangeLog	Fri Jun 28 07:20:34 2013 +0100
@@ -1,3 +1,12 @@
+2013-06-28  Andrew John Hughes  <gnu.andrew@member.fsf.org>
+
+	* NEWS: Mention that 8001330 is not in Zero.
+	* hotspot.map: Update Zero to 2.1.9.
+	* patches/boot/ecj-diamond.patch,
+	* patches/boot/ecj-multicatch.patch,
+	* patches/boot/ecj-stringswitch.patch:
+	Add new cases.
+
 2013-06-25  Andrew John Hughes  <gnu.andrew@member.fsf.org>
 
 	* NEWS: Cleanup security issue duplication.
--- a/NEWS	Tue Jun 25 23:25:25 2013 -0500
+++ b/NEWS	Fri Jun 28 07:20:34 2013 +0100
@@ -26,7 +26,7 @@
   - S8001308: Update display of applet windows
   - S8001309: Better handling of annotation interfaces
   - S8001318, CVE-2013-2447: Socket.getLocalAddress not consistent with InetAddress.getLocalHost
-  - S8001330, CVE-2013-2443: Improve on checking order
+  - S8001330, CVE-2013-2443: Improve on checking order (non-Zero builds only)
   - S8003703, CVE-2013-2412: Update RMI connection dialog box
   - S8004288, CVE-2013-2449: (fs) Files.probeContentType problems
   - S8004584: Augment applet contextualization
--- a/hotspot.map	Tue Jun 25 23:25:25 2013 -0500
+++ b/hotspot.map	Fri Jun 28 07:20:34 2013 +0100
@@ -1,3 +1,3 @@
 # version url changeset sha256sum
 default http://icedtea.classpath.org/hg/release/icedtea7-forest-2.3/hotspot 4e374ade4066 86c8ef401af20352c934a5a6330f41dc65e59b05e3d7875ff9a3476ad1a996a0
-zero http://icedtea.classpath.org/hg/release/icedtea7-forest-2.1/hotspot b965a723122e 43a5529b36cf619199e45832dead0c6b1841337b6416b0123b807e7312cb1912
+zero http://icedtea.classpath.org/hg/release/icedtea7-forest-2.1/hotspot 0d81d5904952 a5a609a3600f474a2333b3f3c3dda735d18f8b8d67e8bdeb33f70d14abc0cdfc
--- a/patches/boot/ecj-diamond.patch	Tue Jun 25 23:25:25 2013 -0500
+++ b/patches/boot/ecj-diamond.patch	Fri Jun 28 07:20:34 2013 +0100
@@ -6327,3 +6327,63 @@
          List<Thread> threads = new ArrayList<Thread>();
          for (int i = 0; i < threadCount; i++) {
              RandomCollector r = new RandomCollector();
+diff -Nru openjdk-boot.orig/jdk/src/share/classes/java/io/ObjectStreamClass.java openjdk-boot/jdk/src/share/classes/java/io/ObjectStreamClass.java
+--- openjdk-boot.orig/jdk/src/share/classes/java/io/ObjectStreamClass.java	2013-06-27 16:06:42.289384018 +0100
++++ openjdk-boot/jdk/src/share/classes/java/io/ObjectStreamClass.java	2013-06-27 16:07:06.489768521 +0100
+@@ -1164,7 +1164,7 @@
+             end = end.getSuperclass();
+         }
+ 
+-        HashSet<String> oscNames = new HashSet<>(3);
++        HashSet<String> oscNames = new HashSet<String>(3);
+ 
+         for (ObjectStreamClass d = this; d != null; d = d.superDesc) {
+             if (oscNames.contains(d.name)) {
+diff -Nru openjdk-boot.orig/jdk/src/share/classes/sun/font/CreatedFontTracker.java openjdk-boot/jdk/src/share/classes/sun/font/CreatedFontTracker.java
+--- openjdk-boot.orig/jdk/src/share/classes/sun/font/CreatedFontTracker.java	2013-06-27 16:06:53.297558922 +0100
++++ openjdk-boot/jdk/src/share/classes/sun/font/CreatedFontTracker.java	2013-06-27 16:07:32.294178507 +0100
+@@ -106,7 +106,7 @@
+      * Note that this only applies to createFont() from an InputStream object.
+      */
+     private static class TempFileDeletionHook {
+-        private static HashMap<File, OutputStream> files = new HashMap<>();
++        private static HashMap<File, OutputStream> files = new HashMap<File, OutputStream>();
+ 
+         private static Thread t = null;
+         static void init() {
+diff --git a/src/share/classes/com/sun/media/sound/AbstractLine.java b/src/share/classes/com/sun/media/sound/AbstractLine.java
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/media/sound/AbstractLine.java
++++ openjdk-boot/jdk/src/share/classes/com/sun/media/sound/AbstractLine.java
+@@ -54,7 +54,7 @@
+      * Contains event dispatcher per thread group.
+      */
+     private static final Map<ThreadGroup, EventDispatcher> dispatchers =
+-            new WeakHashMap<>();
++      new WeakHashMap<ThreadGroup, EventDispatcher>();
+ 
+     /**
+      * Constructs a new AbstractLine.
+diff --git a/src/share/classes/com/sun/media/sound/RealTimeSequencer.java b/src/share/classes/com/sun/media/sound/RealTimeSequencer.java
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java
++++ openjdk-boot/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java
+@@ -59,7 +59,7 @@
+      * dispatcher instance with a factory in EventDispatcher
+      */
+     private static final Map<ThreadGroup, EventDispatcher> dispatchers =
+-            new WeakHashMap<>();
++      new WeakHashMap<ThreadGroup, EventDispatcher>();
+ 
+     /**
+      * All RealTimeSequencers share this info object.
+diff -Nru openjdk-boot.orig/jdk/src/solaris/classes/sun/nio/ch/SctpNet.java openjdk-boot/jdk/src/solaris/classes/sun/nio/ch/SctpNet.java
+--- openjdk-boot.orig/jdk/src/solaris/classes/sun/nio/ch/SctpNet.java	2013-06-27 20:05:19.200970932 +0100
++++ openjdk-boot/jdk/src/solaris/classes/sun/nio/ch/SctpNet.java	2013-06-27 20:05:33.857203747 +0100
+@@ -113,7 +113,7 @@
+             SocketAddress[] saa)
+     {
+          SecurityManager sm = System.getSecurityManager();
+-         Set<SocketAddress> set = new HashSet<>(saa.length);
++         Set<SocketAddress> set = new HashSet<SocketAddress>(saa.length);
+          for (SocketAddress sa : saa) {
+              set.add(getRevealedLocalAddress(sa, sm));
+          }
--- a/patches/boot/ecj-multicatch.patch	Tue Jun 25 23:25:25 2013 -0500
+++ b/patches/boot/ecj-multicatch.patch	Fri Jun 28 07:20:34 2013 +0100
@@ -233,3 +233,54 @@
              throw new InternalError(e.toString());
          } catch (InvocationTargetException e) {
              Throwable t = e.getCause();
+diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/jmx/remote/internal/ArrayNotificationBuffer.java openjdk-boot/jdk/src/share/classes/com/sun/jmx/remote/internal/ArrayNotificationBuffer.java
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/jmx/remote/internal/ArrayNotificationBuffer.java	2013-06-27 15:56:57.456088537 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/jmx/remote/internal/ArrayNotificationBuffer.java	2013-06-27 16:02:12.857102777 +0100
+@@ -402,7 +402,13 @@
+                         try {
+                             ServerNotifForwarder.checkMBeanPermission(this.mBeanServer,
+                                                       candidate.getObjectName(),"addNotificationListener");
+-                        } catch (InstanceNotFoundException | SecurityException e) {
++                        } catch (InstanceNotFoundException e) {
++                            if (logger.debugOn()) {
++                                logger.debug("fetchNotifications", "candidate: " + candidate + " skipped. exception " + e);
++                            }
++                            ++nextSeq;
++                            continue;
++                        } catch (SecurityException e) {
+                             if (logger.debugOn()) {
+                                 logger.debug("fetchNotifications", "candidate: " + candidate + " skipped. exception " + e);
+                             }
+diff -Nru openjdk-boot.orig/jdk/src/share/classes/java/lang/ProcessBuilder.java openjdk-boot/jdk/src/share/classes/java/lang/ProcessBuilder.java
+--- openjdk-boot.orig/jdk/src/share/classes/java/lang/ProcessBuilder.java	2013-06-27 15:56:27.295609027 +0100
++++ openjdk-boot/jdk/src/share/classes/java/lang/ProcessBuilder.java	2013-06-27 16:00:59.631938678 +0100
+@@ -1024,10 +1024,10 @@
+                                      dir,
+                                      redirects,
+                                      redirectErrorStream);
+-        } catch (IOException | IllegalArgumentException e) {
++        } catch (IOException e) {
+             String exceptionInfo = ": " + e.getMessage();
+             Throwable cause = e;
+-            if ((e instanceof IOException) && security != null) {
++            if (security != null) {
+                 // Can not disclose the fail reason for read-protected files.
+                 try {
+                     security.checkRead(prog);
+@@ -1039,6 +1039,16 @@
+             // It's much easier for us to create a high-quality error
+             // message than the low-level C code which found the problem.
+             throw new IOException(
++                "Cannot run program \"" + prog + "\""
++                + (dir == null ? "" : " (in directory \"" + dir + "\")")
++                + exceptionInfo,
++                cause);
++        } catch (IllegalArgumentException e) {
++            String exceptionInfo = ": " + e.getMessage();
++            Throwable cause = e;
++            // It's much easier for us to create a high-quality error
++            // message than the low-level C code which found the problem.
++            throw new IOException(
+                 "Cannot run program \"" + prog + "\""
+                 + (dir == null ? "" : " (in directory \"" + dir + "\")")
+                 + exceptionInfo,
--- a/patches/boot/ecj-stringswitch.patch	Tue Jun 25 23:25:25 2013 -0500
+++ b/patches/boot/ecj-stringswitch.patch	Fri Jun 28 07:20:34 2013 +0100
@@ -362,6 +362,20 @@
              return defc == java.util.logging.Logger.class;
          }
          return false;
+@@ -528,10 +528,10 @@
+     private static boolean canBeCalledVirtual(MemberName mem) {
+         assert(mem.isInvocable());
+         Class<?> defc = mem.getDeclaringClass();
+-        switch (mem.getName()) {
+-        case "checkMemberAccess":
++	String memName = mem.getName();
++	if ("checkMemberAccess".equals(memName)) {
+             return canBeCalledVirtual(mem, java.lang.SecurityManager.class);
+-        case "getContextClassLoader":
++        } else if ("getContextClassLoader".equals(memName)) {
+             return canBeCalledVirtual(mem, java.lang.Thread.class);
+         }
+         return false;
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/java/lang/invoke/MethodHandleProxies.java openjdk-boot/jdk/src/share/classes/java/lang/invoke/MethodHandleProxies.java
 --- openjdk-boot.orig/jdk/src/share/classes/java/lang/invoke/MethodHandleProxies.java	2013-06-21 21:46:14.000000000 +0100
 +++ openjdk-boot/jdk/src/share/classes/java/lang/invoke/MethodHandleProxies.java	2013-06-25 21:52:46.711944282 +0100