diff options
author | Greg Lewis <glewis@FreeBSD.org> | 2012-08-21 04:56:41 +0000 |
---|---|---|
committer | Greg Lewis <glewis@FreeBSD.org> | 2012-08-21 04:56:41 +0000 |
commit | 9b42878dd45767e43d6e3697f8dac467bb9bc858 (patch) | |
tree | 584709e7a5b2b4cb71d3273ba353b5166766abc4 /java/openjdk7 | |
parent | 28b5ffd465ecf5f6eaccde2ae9f713404a27276f (diff) | |
download | ports-9b42878dd45767e43d6e3697f8dac467bb9bc858.tar.gz ports-9b42878dd45767e43d6e3697f8dac467bb9bc858.zip |
Notes
Diffstat (limited to 'java/openjdk7')
-rw-r--r-- | java/openjdk7/Makefile | 22 | ||||
-rw-r--r-- | java/openjdk7/distinfo | 14 | ||||
-rw-r--r-- | java/openjdk7/files/patch-set | 6713 | ||||
-rw-r--r-- | java/openjdk7/files/patch-src-os-bsd-vm-attachListener_bsd.cpp | 16 | ||||
-rw-r--r-- | java/openjdk7/files/patch-src-solaris-native-java-net-NetworkInterface.c | 17 | ||||
-rw-r--r-- | java/openjdk7/files/patch-u5 | 2985 |
6 files changed, 6091 insertions, 3676 deletions
diff --git a/java/openjdk7/Makefile b/java/openjdk7/Makefile index 2fd124a12f9c..489d8087fbc7 100644 --- a/java/openjdk7/Makefile +++ b/java/openjdk7/Makefile @@ -17,9 +17,6 @@ MASTER_SITES= http://download.java.net/openjdk/jdk${JDK_MAJOR_VERSION}u${JDK_MIN http://icedtea.classpath.org/download/drops/:jaf \ ${MASTER_SITE_APACHE:S,%SUBDIR%/,ant/binaries/:ant,} DISTFILES= ${JDK_SRC_DISTFILE}${EXTRACT_SUFX} \ - ${JAXPFILE}:jaxp \ - ${JAXWSFILE}:jaxws \ - ${JAFFILE}:jaf \ ${ANT_DISTFILE}${EXTRACT_SUFX}:ant EXTRACT_ONLY= ${JDK_SRC_DISTFILE}${EXTRACT_SUFX} \ ${ANT_DISTFILE}${EXTRACT_SUFX} @@ -37,16 +34,16 @@ MAKE_JOBS_UNSAFE= YES OPTIONS= POLICY "Install the Unlimited Strength Policy Files" on \ TZUPDATE "Update the time zone data" on -PORT_MINOR_VERSION= 5 -PORT_BUILD_NUMBER= 06 +PORT_MINOR_VERSION= ${JDK_MINOR_VERSION} +PORT_BUILD_NUMBER= ${JDK_BUILD_NUMBER} JDK_MAJOR_VERSION= 7 -JDK_MINOR_VERSION= 4 -JDK_BUILD_NUMBER= 22 -JDK_BUILD_DATE= 02_may_2012 +JDK_MINOR_VERSION= 6 +JDK_BUILD_NUMBER= 24 +JDK_BUILD_DATE= 09_aug_2012 JDK_SRC_DISTFILE= ${PORTNAME}-${JDK_MAJOR_VERSION}u${JDK_MINOR_VERSION}-fcs-src-b${JDK_BUILD_NUMBER}-${JDK_BUILD_DATE} # Use our own version of ant to avoid circular dependencies -ANT_VERSION= 1.8.3 +ANT_VERSION= 1.8.4 ANT_DISTFILE= apache-ant-${ANT_VERSION}-bin LATEST_LINK= openjdk7 @@ -56,10 +53,6 @@ USE_ICONV= YES USE_XORG+= x11 xext xi xrender xt xtst MAKE_JOBS_UNSAFE= yes -JAXPFILE= jaxp145_01.zip -JAXWSFILE= jdk7-jaxws2_2_4-b04-2011_06_01.zip -JAFFILE= jdk7-jaf-2010_08_19.zip - LIB_DEPENDS+= freetype.9:${PORTSDIR}/print/freetype2 \ asound.2:${PORTSDIR}/audio/alsa-lib BUILD_DEPENDS+= zip:${PORTSDIR}/archivers/zip \ @@ -88,7 +81,6 @@ MAKE_ENV+= LANG="C" \ ALT_X11_PATH="${LOCALBASE}" \ ALT_PKG_PATH="${LOCALBASE}" \ ALT_PACKAGE_PATH="${LOCALBASE}" \ - ALT_DROPS_DIR="${DISTDIR}" \ ANT_HOME="${WRKDIR}/apache-ant-${ANT_VERSION}" \ X11DIR="${LOCALBASE}" \ LOCALDIR="${LOCALBASE}" \ @@ -96,6 +88,8 @@ MAKE_ENV+= LANG="C" \ SKIP_COMPARE_IMAGES="true" \ SKIP_FASTDEBUG_BUILD="true" \ SKIP_DEBUG_BUILD="true" \ + ZIP_DEBUGINFO_FILES=0 \ + ENABLE_FULL_DEBUG_SYMBOLS=0 \ PTHREAD_LIBS="${PTHREAD_LIBS}" \ MILESTONE="fcs" \ JDK_MICRO_VERSION="0_0${PORT_MINOR_VERSION}" \ diff --git a/java/openjdk7/distinfo b/java/openjdk7/distinfo index eb3fea433289..4d7d927a43ac 100644 --- a/java/openjdk7/distinfo +++ b/java/openjdk7/distinfo @@ -1,10 +1,4 @@ -SHA256 (openjdk-7u4-fcs-src-b22-02_may_2012.zip) = ed89f8e21c18bf2ff6e6711a351d06b08961a22f3dae6f8c9b4d3683b172a1af -SIZE (openjdk-7u4-fcs-src-b22-02_may_2012.zip) = 97155994 -SHA256 (jaxp145_01.zip) = c5924c6188988e2e8397ee5143bd8eaa062569d052567afd2ac9326a54a848cb -SIZE (jaxp145_01.zip) = 6389175 -SHA256 (jdk7-jaxws2_2_4-b04-2011_06_01.zip) = 6a8734d37553103da47715ebd74077d5397cae4730775b09fa2ab679650aa824 -SIZE (jdk7-jaxws2_2_4-b04-2011_06_01.zip) = 6046342 -SHA256 (jdk7-jaf-2010_08_19.zip) = e6aefedfdbb4673e8019583d1344fb162b94e1b10382c362364dbbfd5889c09e -SIZE (jdk7-jaf-2010_08_19.zip) = 70613 -SHA256 (apache-ant-1.8.3-bin.zip) = bfc608eb306fe743493930d126408ac1cd1df14d67776616289b2f6307b14a53 -SIZE (apache-ant-1.8.3-bin.zip) = 8093329 +SHA256 (openjdk-7u6-fcs-src-b24-09_aug_2012.zip) = 22aec9bcc660d2e6502c9d24e5fdac97da9c4d251dafd87f708bcf6dabbbb431 +SIZE (openjdk-7u6-fcs-src-b24-09_aug_2012.zip) = 103796914 +SHA256 (apache-ant-1.8.4-bin.zip) = d49d60bc0468279125e4a0db4d9b6637cab342a4bd736c90c0b71865b26c1479 +SIZE (apache-ant-1.8.4-bin.zip) = 8043520 diff --git a/java/openjdk7/files/patch-set b/java/openjdk7/files/patch-set index 76d84639d284..6532c69bbeda 100644 --- a/java/openjdk7/files/patch-set +++ b/java/openjdk7/files/patch-set @@ -1,5 +1,5 @@ ---- .hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ .hgtags 2012-05-15 19:58:20.000000000 -0700 +--- .hgtags 2012-08-10 09:07:00.000000000 -0700 ++++ .hgtags 2012-08-19 11:38:54.000000000 -0700 @@ -123,6 +123,7 @@ 2d38c2a79c144c30cd04d143d83ee7ec6af40771 jdk7-b146 3ac30b3852876ccad6bd61697b5f9efa91ca7bc6 jdk7u1-b01 @@ -8,8 +8,15 @@ 34451dc0580d5c95d97b95a564e6198f36545d68 jdk7u1-b02 bf735d852f79bdbb3373c777eec3ff27e035e7ba jdk7u1-b03 f66a2bada589f4157789e6f66472954d2f1c114e jdk7u1-b04 ---- corba/.hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ corba/.hgtags 2012-05-15 20:07:03.000000000 -0700 +@@ -197,5 +198,4 @@ + 29f6fb1833eb2a696b95e8985126f2d70f511a82 jdk7u6-b21 + 31cdab09d719fe60876c7f3a472386c1455d93e2 jdk7u6-b22 + d1c709f1196a73d1df10d04a221b10e30fd2eb48 jdk7u6-b23 +-1ab3edf5061fdde3a6f6510373a92444445af710 jdk7u8-b01 +-d7a94c8cbbbfadbd9e2f3e4737eb7deb572dedc9 jdk7u8-b02 ++e4def733cc8c58e83b7cefa7edd89a3e2b793520 jdk7u6-b24 +--- corba/.hgtags 2012-08-10 09:09:50.000000000 -0700 ++++ corba/.hgtags 2012-08-19 11:44:59.000000000 -0700 @@ -123,6 +123,7 @@ 770227a4087e4e401fe87ccd19738440111c3948 jdk7-b146 36f0efbc66ef8ace3cca8aa8d0c88f3334080f8a jdk7u1-b01 @@ -18,8 +25,35 @@ 9515a2d034b4727c11aeea36354a549fbc469c4f jdk7u1-b02 dd71cb354c573c1addcda269a7dd9144bfce9587 jdk7u1-b03 eaee830124aa453627591d8f9eccb39d7e040876 jdk7u1-b04 ---- hotspot/.hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/.hgtags 2012-05-16 19:03:30.000000000 -0700 +@@ -197,5 +198,4 @@ + 353c15c4bc371f2f8258344c988d1403477cc140 jdk7u6-b21 + 793b80c0316fcafa18668bced26acb41af3be07d jdk7u6-b22 + 2a8376123fbb81bc4b2f643ff7cfaf7f87b21c35 jdk7u6-b23 +-353c15c4bc371f2f8258344c988d1403477cc140 jdk7u8-b01 +-d17ca8d088f7cc0dd42230472f534c8d1e415bcb jdk7u8-b02 ++02512f61591f55d84458d1ea4ce84eecb7324f89 jdk7u6-b24 +--- get_source.sh 2012-08-10 09:07:01.000000000 -0700 ++++ get_source.sh 2012-08-19 11:38:54.000000000 -0700 +@@ -1,7 +1,7 @@ + #!/bin/sh + + # +-# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -26,7 +26,7 @@ + # + + # Get clones of all nested repositories +-sh ./make/scripts/hgforest.sh clone $* ++sh ./make/scripts/hgforest.sh clone + + # Update all existing repositories to the latest sources + sh ./make/scripts/hgforest.sh pull -u +--- hotspot/.hgtags 2012-08-10 09:20:36.000000000 -0700 ++++ hotspot/.hgtags 2012-08-19 12:11:03.000000000 -0700 @@ -182,6 +182,7 @@ 38fa55e5e79232d48f1bb8cf27d88bc094c9375a hs21-b16 81d815b05abb564aa1f4100ae13491c949b9a07e jdk7-b147 @@ -28,8 +62,15 @@ 9b0ca45cd756d538c4c30afab280a91868eee1a5 jdk7u2-b01 0cc8a70952c368e06de2adab1f2649a408f5e577 jdk8-b01 31e253c1da429124bb87570ab095d9bc89850d0a jdk8-b02 ---- hotspot/agent/src/os/bsd/symtab.c 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/agent/src/os/bsd/symtab.c 2012-05-16 19:16:01.000000000 -0700 +@@ -318,5 +319,4 @@ + 02a6c89432d724119565f9ba25672829b136fc5f jdk7u6-b21 + a79d86eef6ac995a1fc35554f082f3a61abe9ae0 jdk7u6-b22 + df57f6208cb76b4e8d1a0bd0eea3d2ad577cb79b jdk7u6-b23 +-02a6c89432d724119565f9ba25672829b136fc5f jdk7u8-b01 +-528502f930967f70c320472a002418f1e38029e0 jdk7u8-b02 ++b03c2687fb16514652e79261ad68d2c601dcee62 jdk7u6-b24 +--- hotspot/agent/src/os/bsd/symtab.c 2012-08-10 09:21:04.000000000 -0700 ++++ hotspot/agent/src/os/bsd/symtab.c 2012-08-19 12:11:03.000000000 -0700 @@ -94,7 +94,7 @@ if (cursct->sh_type == SHT_SYMTAB || cursct->sh_type == SHT_STRTAB || @@ -39,8 +80,8 @@ goto quit; } } ---- hotspot/agent/src/share/classes/sun/jvm/hotspot/HotSpotAgent.java 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/agent/src/share/classes/sun/jvm/hotspot/HotSpotAgent.java 2012-05-16 19:03:30.000000000 -0700 +--- hotspot/agent/src/share/classes/sun/jvm/hotspot/HotSpotAgent.java 2012-08-10 09:21:14.000000000 -0700 ++++ hotspot/agent/src/share/classes/sun/jvm/hotspot/HotSpotAgent.java 2012-08-19 12:11:03.000000000 -0700 @@ -33,6 +33,7 @@ import sun.jvm.hotspot.debugger.remote.*; import sun.jvm.hotspot.debugger.windbg.*; @@ -49,8 +90,8 @@ import sun.jvm.hotspot.memory.*; import sun.jvm.hotspot.oops.*; import sun.jvm.hotspot.runtime.*; ---- hotspot/agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java 2012-05-16 19:03:30.000000000 -0700 +--- hotspot/agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java 2012-08-10 09:21:38.000000000 -0700 ++++ hotspot/agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java 2012-08-19 12:11:03.000000000 -0700 @@ -35,6 +35,7 @@ import sun.jvm.hotspot.debugger.windbg.*; import sun.jvm.hotspot.debugger.linux.*; @@ -59,8 +100,361 @@ import sun.jvm.hotspot.debugger.remote.*; import sun.jvm.hotspot.livejvm.*; import sun.jvm.hotspot.memory.*; ---- hotspot/make/bsd/makefiles/launcher.make 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/make/bsd/makefiles/launcher.make 2012-05-16 20:03:48.000000000 -0700 +--- hotspot/make/bsd/Makefile 2012-08-10 09:22:55.000000000 -0700 ++++ hotspot/make/bsd/Makefile 2012-08-19 12:11:04.000000000 -0700 +@@ -1,5 +1,5 @@ + # +-# Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -211,6 +211,8 @@ + BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OSNAME) SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) LIBRARY_SUFFIX=$(LIBRARY_SUFFIX) + BUILDTREE_VARS += HOTSPOT_RELEASE_VERSION=$(HOTSPOT_RELEASE_VERSION) HOTSPOT_BUILD_VERSION=$(HOTSPOT_BUILD_VERSION) JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION) + ++BUILDTREE_VARS += ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS) OBJCOPY=$(OBJCOPY) STRIP_POLICY=$(STRIP_POLICY) ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES) ZIPEXE=$(ZIPEXE) ++ + BUILDTREE = $(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_VARS) + + #------------------------------------------------------------------------------- +@@ -337,9 +339,11 @@ + + # Doc target. This is the same for all build options. + # Hence create a docs directory beside ...$(ARCH)_[...] ++# We specify 'BUILD_FLAVOR=product' so that the proper ++# ENABLE_FULL_DEBUG_SYMBOLS value is used. + docs: checks + $(QUIETLY) mkdir -p $(SUBDIR_DOCS) +- $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) jvmtidocs ++ $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs + + # Synonyms for win32-like targets. + compiler2: jvmg product +--- hotspot/make/bsd/makefiles/buildtree.make 2012-08-10 09:22:57.000000000 -0700 ++++ hotspot/make/bsd/makefiles/buildtree.make 2012-08-19 12:11:04.000000000 -0700 +@@ -1,5 +1,5 @@ + # +-# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -242,6 +242,16 @@ + echo "$(call gamma-path,commonsrc,os/posix/vm)"; \ + [ -n "$(CFLAGS_BROWSE)" ] && \ + echo && echo "CFLAGS_BROWSE = $(CFLAGS_BROWSE)"; \ ++ [ -n "$(ENABLE_FULL_DEBUG_SYMBOLS)" ] && \ ++ echo && echo "ENABLE_FULL_DEBUG_SYMBOLS = $(ENABLE_FULL_DEBUG_SYMBOLS)"; \ ++ [ -n "$(OBJCOPY)" ] && \ ++ echo && echo "OBJCOPY = $(OBJCOPY)"; \ ++ [ -n "$(STRIP_POLICY)" ] && \ ++ echo && echo "STRIP_POLICY = $(STRIP_POLICY)"; \ ++ [ -n "$(ZIP_DEBUGINFO_FILES)" ] && \ ++ echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \ ++ [ -n "$(ZIPEXE)" ] && \ ++ echo && echo "ZIPEXE = $(ZIPEXE)"; \ + [ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \ + echo && \ + echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \ +@@ -359,7 +369,7 @@ + $(QUIETLY) ( \ + $(BUILDTREE_COMMENT); \ + echo "JDK=${JAVA_HOME}"; \ +- ) > $@ ++ ) > $@ + + .dbxrc: $(BUILDTREE_MAKE) + @echo Creating $@ ... +--- hotspot/make/bsd/makefiles/defs.make 2012-08-10 09:22:57.000000000 -0700 ++++ hotspot/make/bsd/makefiles/defs.make 2012-08-19 12:11:04.000000000 -0700 +@@ -86,7 +86,7 @@ + VM_PLATFORM = bsd_i486 + HS_ARCH = x86 + # We have to reset ARCH to i386 since SRCARCH relies on it +- ARCH = i386 ++ ARCH = i386 + endif + endif + +@@ -124,6 +124,107 @@ + HS_ARCH = ppc + endif + ++# determine if HotSpot is being built in JDK6 or earlier version ++JDK6_OR_EARLIER=0 ++ifeq "$(shell expr \( '$(JDK_MAJOR_VERSION)' != '' \& '$(JDK_MINOR_VERSION)' != '' \& '$(JDK_MICRO_VERSION)' != '' \))" "1" ++ # if the longer variable names (newer build style) are set, then check those ++ ifeq "$(shell expr \( $(JDK_MAJOR_VERSION) = 1 \& $(JDK_MINOR_VERSION) \< 7 \))" "1" ++ JDK6_OR_EARLIER=1 ++ endif ++else ++ # the longer variables aren't set so check the shorter variable names ++ ifeq "$(shell expr \( '$(JDK_MAJOR_VER)' = 1 \& '$(JDK_MINOR_VER)' \< 7 \))" "1" ++ JDK6_OR_EARLIER=1 ++ endif ++endif ++ ++ifeq ($(JDK6_OR_EARLIER),0) ++ # Full Debug Symbols is supported on JDK7 or newer. ++ # The Full Debug Symbols (FDS) default for BUILD_FLAVOR == product ++ # builds is enabled with debug info files ZIP'ed to save space. For ++ # BUILD_FLAVOR != product builds, FDS is always enabled, after all a ++ # debug build without debug info isn't very useful. ++ # The ZIP_DEBUGINFO_FILES option only has meaning when FDS is enabled. ++ # ++ # If you invoke a build with FULL_DEBUG_SYMBOLS=0, then FDS will be ++ # disabled for a BUILD_FLAVOR == product build. ++ # ++ # Note: Use of a different variable name for the FDS override option ++ # versus the FDS enabled check is intentional (FULL_DEBUG_SYMBOLS ++ # versus ENABLE_FULL_DEBUG_SYMBOLS). For auto build systems that pass ++ # in options via environment variables, use of distinct variables ++ # prevents strange behaviours. For example, in a BUILD_FLAVOR != ++ # product build, the FULL_DEBUG_SYMBOLS environment variable will be ++ # 0, but the ENABLE_FULL_DEBUG_SYMBOLS make variable will be 1. If ++ # the same variable name is used, then different values can be picked ++ # up by different parts of the build. Just to be clear, we only need ++ # two variable names because the incoming option value can be ++ # overridden in some situations, e.g., a BUILD_FLAVOR != product ++ # build. ++ ++ ifeq ($(BUILD_FLAVOR), product) ++ FULL_DEBUG_SYMBOLS ?= 1 ++ ENABLE_FULL_DEBUG_SYMBOLS = $(FULL_DEBUG_SYMBOLS) ++ else ++ # debug variants always get Full Debug Symbols (if available) ++ ENABLE_FULL_DEBUG_SYMBOLS = 1 ++ endif ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)") ++ # since objcopy is optional, we set ZIP_DEBUGINFO_FILES later ++ ++ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ # Default OBJCOPY comes from GNU Binutils on Linux: ++ DEF_OBJCOPY=/usr/bin/objcopy ++ ifdef CROSS_COMPILE_ARCH ++ # don't try to generate .debuginfo files when cross compiling ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: cross compiling for ARCH $(CROSS_COMPILE_ARCH)," \ ++ "skipping .debuginfo generation.") ++ OBJCOPY= ++ else ++ OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY)) ++ ifneq ($(ALT_OBJCOPY),) ++ _JUNK_ := $(shell echo >&2 "INFO: ALT_OBJCOPY=$(ALT_OBJCOPY)") ++ OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY)) ++ endif ++ endif ++ else ++ OBJCOPY= ++ endif ++ ++ ifeq ($(OBJCOPY),) ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: no objcopy cmd found so cannot create .debuginfo files.") ++ ENABLE_FULL_DEBUG_SYMBOLS=0 ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)") ++ else ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: $(OBJCOPY) cmd found so will create .debuginfo files.") ++ ++ # Library stripping policies for .debuginfo configs: ++ # all_strip - strips everything from the library ++ # min_strip - strips most stuff from the library; leaves minimum symbols ++ # no_strip - does not strip the library at all ++ # ++ # Oracle security policy requires "all_strip". A waiver was granted on ++ # 2011.09.01 that permits using "min_strip" in the Java JDK and Java JRE. ++ # ++ # Currently, STRIP_POLICY is only used when Full Debug Symbols is enabled. ++ # ++ STRIP_POLICY ?= min_strip ++ ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: STRIP_POLICY=$(STRIP_POLICY)") ++ ++ ZIP_DEBUGINFO_FILES ?= 1 ++ ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES)") ++ endif ++endif ++ + JDK_INCLUDE_SUBDIR=bsd + + # Library suffix +@@ -141,18 +242,39 @@ + + # client and server subdirectories have symbolic links to ../libjsig.so + EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libjsig.$(LIBRARY_SUFFIX) ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libjsig.diz ++ else ++ EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libjsig.debuginfo ++ endif ++endif + EXPORT_SERVER_DIR = $(EXPORT_JRE_LIB_ARCH_DIR)/server + EXPORT_CLIENT_DIR = $(EXPORT_JRE_LIB_ARCH_DIR)/client + + ifndef BUILD_CLIENT_ONLY + EXPORT_LIST += $(EXPORT_SERVER_DIR)/Xusage.txt + EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.$(LIBRARY_SUFFIX) ++ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.diz ++ else ++ EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.debuginfo ++ endif ++ endif + endif + + ifneq ($(ZERO_BUILD), true) + ifeq ($(ARCH_DATA_MODEL), 32) + EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt + EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX) ++ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.diz ++ else ++ EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.debuginfo ++ endif ++ endif + endif + endif + +@@ -164,6 +286,15 @@ + $(EXPORT_LIB_DIR)/sa-jdi.jar + ADD_SA_BINARIES/universal = $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.$(LIBRARY_SUFFIX) \ + $(EXPORT_LIB_DIR)/sa-jdi.jar ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ ADD_SA_BINARIES/x86 += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.diz ++ ADD_SA_BINARIES/sparc += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.diz ++ else ++ ADD_SA_BINARIES/x86 += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.debuginfo ++ ADD_SA_BINARIES/sparc += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.debuginfo ++ endif ++endif + ADD_SA_BINARIES/ppc = + ADD_SA_BINARIES/ia64 = + ADD_SA_BINARIES/arm = +--- hotspot/make/bsd/makefiles/gcc.make 2012-08-10 09:22:57.000000000 -0700 ++++ hotspot/make/bsd/makefiles/gcc.make 2012-08-19 12:11:04.000000000 -0700 +@@ -1,5 +1,5 @@ + # +-# Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -124,7 +124,11 @@ + ARCHFLAG/ia64 = + ARCHFLAG/sparc = -m32 -mcpu=v9 + ARCHFLAG/sparcv9 = -m64 -mcpu=v9 ++ARCHFLAG/arm = -fsigned-char + ARCHFLAG/zero = $(ZERO_ARCHFLAG) ++ifndef E500V2 ++ARCHFLAG/ppc = -mcpu=powerpc ++endif + + # Darwin-specific build flags + ifeq ($(OS_VENDOR), Darwin) +@@ -285,6 +289,26 @@ + DEBUG_CFLAGS += -gstabs + endif + ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ FASTDEBUG_CFLAGS/ia64 = -g ++ FASTDEBUG_CFLAGS/amd64 = -g ++ FASTDEBUG_CFLAGS/arm = -g ++ FASTDEBUG_CFLAGS/ppc = -g ++ FASTDEBUG_CFLAGS += $(DEBUG_CFLAGS/$(BUILDARCH)) ++ ifeq ($(FASTDEBUG_CFLAGS/$(BUILDARCH)),) ++ FASTDEBUG_CFLAGS += -gstabs ++ endif ++ ++ OPT_CFLAGS/ia64 = -g ++ OPT_CFLAGS/amd64 = -g ++ OPT_CFLAGS/arm = -g ++ OPT_CFLAGS/ppc = -g ++ OPT_CFLAGS += $(OPT_CFLAGS/$(BUILDARCH)) ++ ifeq ($(OPT_CFLAGS/$(BUILDARCH)),) ++ OPT_CFLAGS += -gstabs ++ endif ++endif ++ + # DEBUG_BINARIES overrides everything, use full -g debug information + ifeq ($(DEBUG_BINARIES), true) + DEBUG_CFLAGS = -g +@@ -302,3 +326,9 @@ + ifdef MINIMIZE_RAM_USAGE + CFLAGS += -DMINIMIZE_RAM_USAGE + endif ++ ++ifdef CROSS_COMPILE_ARCH ++ STRIP = $(ALT_COMPILER_PATH)/strip ++else ++ STRIP = strip ++endif +--- hotspot/make/bsd/makefiles/jsig.make 2012-08-10 09:22:58.000000000 -0700 ++++ hotspot/make/bsd/makefiles/jsig.make 2012-08-19 12:11:04.000000000 -0700 +@@ -36,9 +36,16 @@ + LIBJSIG_G = lib$(JSIG_G).so + endif + ++LIBJSIG_DEBUGINFO = lib$(JSIG).debuginfo ++LIBJSIG_DIZ = lib$(JSIG).diz ++LIBJSIG_G_DEBUGINFO = lib$(JSIG_G).debuginfo ++LIBJSIG_G_DIZ = lib$(JSIG_G).diz ++ + JSIGSRCDIR = $(GAMMADIR)/src/os/$(Platform_os_family)/vm + + DEST_JSIG = $(JDK_LIBDIR)/$(LIBJSIG) ++DEST_JSIG_DEBUGINFO = $(JDK_LIBDIR)/$(LIBJSIG_DEBUGINFO) ++DEST_JSIG_DIZ = $(JDK_LIBDIR)/$(LIBJSIG_DIZ) + + LIBJSIG_MAPFILE = $(MAKEFILES_DIR)/mapfile-vers-jsig + +@@ -57,11 +64,33 @@ + $(LIBJSIG): $(JSIGSRCDIR)/jsig.c $(LIBJSIG_MAPFILE) + @echo Making signal interposition lib... + $(QUIETLY) $(CC) $(SYMFLAG) $(ARCHFLAG) $(SHARED_FLAG) $(PICFLAG) \ +- $(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) -o $@ $< ++ $(LFLAGS_JSIG) $(JSIG_DEBUG_CFLAGS) -o $@ $< + $(QUIETLY) [ -f $(LIBJSIG_G) ] || { ln -s $@ $(LIBJSIG_G); } ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJSIG_DEBUGINFO) ++ $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJSIG_DEBUGINFO) $@ ++ ifeq ($(STRIP_POLICY),all_strip) ++ $(QUIETLY) $(STRIP) $@ ++ else ++ ifeq ($(STRIP_POLICY),min_strip) ++ $(QUIETLY) $(STRIP) -S $@ ++ # implied else here is no stripping at all ++ endif ++ endif ++ [ -f $(LIBJSIG_G_DEBUGINFO) ] || { ln -s $(LIBJSIG_DEBUGINFO) $(LIBJSIG_G_DEBUGINFO); } ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ $(ZIPEXE) -q -y $(LIBJSIG_DIZ) $(LIBJSIG_DEBUGINFO) $(LIBJSIG_G_DEBUGINFO) ++ $(RM) $(LIBJSIG_DEBUGINFO) $(LIBJSIG_G_DEBUGINFO) ++ [ -f $(LIBJSIG_G_DIZ) ] || { ln -s $(LIBJSIG_DIZ) $(LIBJSIG_G_DIZ); } ++ endif ++endif + + install_jsig: $(LIBJSIG) + @echo "Copying $(LIBJSIG) to $(DEST_JSIG)" ++ $(QUIETLY) test -f $(LIBJSIG_DEBUGINFO) && \ ++ cp -f $(LIBJSIG_DEBUGINFO) $(DEST_JSIG_DEBUGINFO) ++ $(QUIETLY) test -f $(LIBJSIG_DIZ) && \ ++ cp -f $(LIBJSIG_DIZ) $(DEST_JSIG_DIZ) + $(QUIETLY) cp -f $(LIBJSIG) $(DEST_JSIG) && echo "Done" + + .PHONY: install_jsig +--- hotspot/make/bsd/makefiles/launcher.make 2012-08-10 09:22:58.000000000 -0700 ++++ hotspot/make/bsd/makefiles/launcher.make 2012-08-19 12:11:04.000000000 -0700 @@ -50,7 +50,7 @@ LIBS_LAUNCHER += $(STATIC_STDCXX) $(LIBS) else @@ -70,8 +464,8 @@ # The gamma launcher runs the JDK from $JAVA_HOME, overriding the JVM with a # freshly built JVM at ./libjvm.{so|dylib}. This is accomplished by setting ---- hotspot/make/bsd/makefiles/mapfile-vers-debug 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/make/bsd/makefiles/mapfile-vers-debug 2012-05-19 10:35:54.000000000 -0700 +--- hotspot/make/bsd/makefiles/mapfile-vers-debug 2012-08-10 09:22:58.000000000 -0700 ++++ hotspot/make/bsd/makefiles/mapfile-vers-debug 2012-08-19 12:11:04.000000000 -0700 @@ -221,6 +221,7 @@ JVM_SetArrayElement; JVM_SetClassSigners; @@ -105,8 +499,8 @@ # debug JVM JVM_AccessVMBooleanFlag; JVM_AccessVMIntFlag; ---- hotspot/make/bsd/makefiles/mapfile-vers-product 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/make/bsd/makefiles/mapfile-vers-product 2012-05-19 10:36:22.000000000 -0700 +--- hotspot/make/bsd/makefiles/mapfile-vers-product 2012-08-10 09:22:58.000000000 -0700 ++++ hotspot/make/bsd/makefiles/mapfile-vers-product 2012-08-19 12:11:04.000000000 -0700 @@ -221,6 +221,7 @@ JVM_SetArrayElement; JVM_SetClassSigners; @@ -140,9 +534,184 @@ # miscellaneous functions jio_fprintf; jio_printf; ---- hotspot/make/solaris/makefiles/defs.make 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/make/solaris/makefiles/defs.make 2012-05-17 14:53:53.000000000 -0700 -@@ -164,8 +164,8 @@ +--- hotspot/make/bsd/makefiles/ppc.make 2012-08-10 09:22:58.000000000 -0700 ++++ hotspot/make/bsd/makefiles/ppc.make 2012-08-19 12:11:04.000000000 -0700 +@@ -28,3 +28,6 @@ + # Must also specify if CPU is big endian + CFLAGS += -DVM_BIG_ENDIAN + ++ifdef E500V2 ++ASFLAGS += -Wa,-mspe -Wa,--defsym -Wa,E500V2=1 ++endif +--- hotspot/make/bsd/makefiles/saproc.make 2012-08-10 09:22:59.000000000 -0700 ++++ hotspot/make/bsd/makefiles/saproc.make 2012-08-19 12:11:04.000000000 -0700 +@@ -36,6 +36,11 @@ + LIBSAPROC_G = lib$(SAPROC_G).so + endif + ++LIBSAPROC_DEBUGINFO = lib$(SAPROC).debuginfo ++LIBSAPROC_DIZ = lib$(SAPROC).diz ++LIBSAPROC_G_DEBUGINFO = lib$(SAPROC_G).debuginfo ++LIBSAPROC_G_DIZ = lib$(SAPROC_G).diz ++ + AGENT_DIR = $(GAMMADIR)/agent + + SASRCDIR = $(AGENT_DIR)/src/os/$(Platform_os_family) +@@ -66,7 +71,9 @@ + + SAMAPFILE = $(SASRCDIR)/mapfile + +-DEST_SAPROC = $(JDK_LIBDIR)/$(LIBSAPROC) ++DEST_SAPROC = $(JDK_LIBDIR)/$(LIBSAPROC) ++DEST_SAPROC_DEBUGINFO = $(JDK_LIBDIR)/$(LIBSAPROC_DEBUGINFO) ++DEST_SAPROC_DIZ = $(JDK_LIBDIR)/$(LIBSAPROC_DIZ) + + # DEBUG_BINARIES overrides everything, use full -g debug information + ifeq ($(DEBUG_BINARIES), true) +@@ -114,10 +121,32 @@ + -o $@ \ + $(SALIBS) + $(QUIETLY) [ -f $(LIBSAPROC_G) ] || { ln -s $@ $(LIBSAPROC_G); } ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBSAPROC_DEBUGINFO) ++ $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBSAPROC_DEBUGINFO) $@ ++ ifeq ($(STRIP_POLICY),all_strip) ++ $(QUIETLY) $(STRIP) $@ ++ else ++ ifeq ($(STRIP_POLICY),min_strip) ++ $(QUIETLY) $(STRIP) -S $@ ++ # implied else here is no stripping at all ++ endif ++ endif ++ [ -f $(LIBSAPROC_G_DEBUGINFO) ] || { ln -s $(LIBSAPROC_DEBUGINFO) $(LIBSAPROC_G_DEBUGINFO); } ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ $(ZIPEXE) -q -y $(LIBSAPROC_DIZ) $(LIBSAPROC_DEBUGINFO) $(LIBSAPROC_G_DEBUGINFO) ++ $(RM) $(LIBSAPROC_DEBUGINFO) $(LIBSAPROC_G_DEBUGINFO) ++ [ -f $(LIBSAPROC_G_DIZ) ] || { ln -s $(LIBSAPROC_DIZ) $(LIBSAPROC_G_DIZ); } ++ endif ++endif + + install_saproc: $(BUILDLIBSAPROC) + $(QUIETLY) if [ -e $(LIBSAPROC) ] ; then \ + echo "Copying $(LIBSAPROC) to $(DEST_SAPROC)"; \ ++ test -f $(LIBSAPROC_DEBUGINFO) && \ ++ cp -f $(LIBSAPROC_DEBUGINFO) $(DEST_SAPROC_DEBUGINFO); \ ++ test -f $(LIBSAPROC_DIZ) && \ ++ cp -f $(LIBSAPROC_DIZ) $(DEST_SAPROC_DIZ); \ + cp -f $(LIBSAPROC) $(DEST_SAPROC) && echo "Done"; \ + fi + +--- hotspot/make/bsd/makefiles/vm.make 2012-08-10 09:22:59.000000000 -0700 ++++ hotspot/make/bsd/makefiles/vm.make 2012-08-19 12:11:04.000000000 -0700 +@@ -1,5 +1,5 @@ + # +-# Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -60,10 +60,16 @@ + # The order is important for the precompiled headers to work. + INCLUDES += $(PRECOMPILED_HEADER_DIR:%=-I%) $(Src_Dirs_I:%=-I%) + +-ifeq (${VERSION}, debug) ++# SYMFLAG is used by {jsig,saproc}.make ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ # always build with debug info when we can create .debuginfo files + SYMFLAG = -g + else +- SYMFLAG = ++ ifeq (${VERSION}, debug) ++ SYMFLAG = -g ++ else ++ SYMFLAG = ++ endif + endif + + # HOTSPOT_RELEASE_VERSION and HOTSPOT_BUILD_VERSION are defined +@@ -100,9 +106,11 @@ + CXXFLAGS += -DDEFAULT_LIBPATH="\"$(DEFAULT_LIBPATH)\"" + endif + +-ifndef JAVASE_EMBEDDED ++ifndef JAVASE_EMBEDDED ++ifneq (${ARCH},arm) + CFLAGS += -DINCLUDE_TRACE + endif ++endif + + # CFLAGS_WARN holds compiler options to suppress/enable warnings. + CFLAGS += $(CFLAGS_WARN/BYFILE) +@@ -145,6 +153,11 @@ + LIBJVM_G = lib$(JVM)$(G_SUFFIX).so + endif + ++LIBJVM_DEBUGINFO = lib$(JVM).debuginfo ++LIBJVM_DIZ = lib$(JVM).diz ++LIBJVM_G_DEBUGINFO = lib$(JVM)$(G_SUFFIX).debuginfo ++LIBJVM_G_DIZ = lib$(JVM)$(G_SUFFIX).diz ++ + SPECIAL_PATHS:=adlc c1 gc_implementation opto shark libadt + + SOURCE_PATHS=\ +@@ -155,11 +168,13 @@ + SOURCE_PATHS+=$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm + SOURCE_PATHS+=$(HS_COMMON_SRC)/os_cpu/$(Platform_os_arch)/vm + +-ifndef JAVASE_EMBEDDED ++ifndef JAVASE_EMBEDDED ++ifneq (${ARCH},arm) + SOURCE_PATHS+=$(shell if [ -d $(HS_ALT_SRC)/share/vm/jfr ]; then \ + find $(HS_ALT_SRC)/share/vm/jfr -type d; \ + fi) + endif ++endif + + CORE_PATHS=$(foreach path,$(SOURCE_PATHS),$(call altsrc,$(path)) $(path)) + CORE_PATHS+=$(GENERATED)/jvmtifiles +@@ -316,11 +331,38 @@ + rm -f $@.1; ln -s $@ $@.1; \ + [ -f $(LIBJVM_G) ] || { ln -s $@ $(LIBJVM_G); ln -s $@.1 $(LIBJVM_G).1; }; \ + } ++ifeq ($(CROSS_COMPILE_ARCH),) ++ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ $(QUIETLY) $(OBJCOPY) --only-keep-debug $@ $(LIBJVM_DEBUGINFO) ++ $(QUIETLY) $(OBJCOPY) --add-gnu-debuglink=$(LIBJVM_DEBUGINFO) $@ ++ ifeq ($(STRIP_POLICY),all_strip) ++ $(QUIETLY) $(STRIP) $@ ++ else ++ ifeq ($(STRIP_POLICY),min_strip) ++ $(QUIETLY) $(STRIP) -S $@ ++ # implied else here is no stripping at all ++ endif ++ endif ++ $(QUIETLY) [ -f $(LIBJVM_G_DEBUGINFO) ] || ln -s $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) ++ ifeq ($(ZIP_DEBUGINFO_FILES),1) ++ $(ZIPEXE) -q -y $(LIBJVM_DIZ) $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) ++ $(RM) $(LIBJVM_DEBUGINFO) $(LIBJVM_G_DEBUGINFO) ++ [ -f $(LIBJVM_G_DIZ) ] || { ln -s $(LIBJVM_DIZ) $(LIBJVM_G_DIZ); } ++ endif ++ endif ++endif + +-DEST_JVM = $(JDK_LIBDIR)/$(VM_SUBDIR)/$(LIBJVM) ++DEST_SUBDIR = $(JDK_LIBDIR)/$(VM_SUBDIR) ++DEST_JVM = $(DEST_SUBDIR)/$(LIBJVM) ++DEST_JVM_DEBUGINFO = $(DEST_SUBDIR)/$(LIBJVM_DEBUGINFO) ++DEST_JVM_DIZ = $(DEST_SUBDIR)/$(LIBJVM_DIZ) + + install_jvm: $(LIBJVM) + @echo "Copying $(LIBJVM) to $(DEST_JVM)" ++ $(QUIETLY) test -f $(LIBJVM_DEBUGINFO) && \ ++ cp -f $(LIBJVM_DEBUGINFO) $(DEST_JVM_DEBUGINFO) ++ $(QUIETLY) test -f $(LIBJVM_DIZ) && \ ++ cp -f $(LIBJVM_DIZ) $(DEST_JVM_DIZ) + $(QUIETLY) cp -f $(LIBJVM) $(DEST_JVM) && echo "Done" + + #---------------------------------------------------------------------- +--- hotspot/make/solaris/makefiles/defs.make 2012-08-10 09:23:12.000000000 -0700 ++++ hotspot/make/solaris/makefiles/defs.make 2012-08-19 12:11:04.000000000 -0700 +@@ -194,8 +194,8 @@ endif ifeq ($(ARCH_DATA_MODEL), 32) EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt @@ -153,8 +722,8 @@ EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm_dtrace.$(LIBRARY_SUFFIX) EXPORT_LIST += $(EXPORT_CLIENT_DIR)/64/libjvm_db.$(LIBRARY_SUFFIX) EXPORT_LIST += $(EXPORT_CLIENT_DIR)/64/libjvm_dtrace.$(LIBRARY_SUFFIX) ---- hotspot/src/cpu/sparc/vm/globals_sparc.hpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/cpu/sparc/vm/globals_sparc.hpp 2012-05-16 19:03:31.000000000 -0700 +--- hotspot/src/cpu/sparc/vm/globals_sparc.hpp 2012-08-10 09:23:56.000000000 -0700 ++++ hotspot/src/cpu/sparc/vm/globals_sparc.hpp 2012-08-19 12:11:04.000000000 -0700 @@ -71,7 +71,11 @@ define_pd_global(bool, RewriteBytecodes, true); define_pd_global(bool, RewriteFrequentPairs, true); @@ -167,8 +736,22 @@ // GC Ergo Flags define_pd_global(intx, CMSYoungGenPerWorker, 16*M); // default max size of CMS young gen, per GC worker thread +--- hotspot/src/os/bsd/vm/attachListener_bsd.cpp 2012-08-10 09:24:15.000000000 -0700 ++++ hotspot/src/os/bsd/vm/attachListener_bsd.cpp 2012-08-19 12:11:05.000000000 -0700 +@@ -212,7 +212,10 @@ + // (this is the default on linux, but not on mac os) + RESTARTABLE(::chown(initial_path, geteuid(), getegid()), res); + if (res == 0) { +- res = ::rename(initial_path, path); ++ RESTARTABLE(::chown(initial_path, geteuid(), getegid()), res); ++ if (res == 0) { ++ res = ::rename(initial_path, path); ++ } + } + } + } --- hotspot/src/os/bsd/vm/decoder_bsd.cpp 1969-12-31 16:00:00.000000000 -0800 -+++ hotspot/src/os/bsd/vm/decoder_bsd.cpp 2012-05-25 00:08:53.000000000 -0700 ++++ hotspot/src/os/bsd/vm/decoder_bsd.cpp 2012-08-19 12:11:05.000000000 -0700 @@ -0,0 +1,46 @@ +/* + * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. @@ -216,9 +799,68 @@ + return false; +} + ---- hotspot/src/os/bsd/vm/os_bsd.cpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/os/bsd/vm/os_bsd.cpp 2012-05-19 10:38:46.000000000 -0700 -@@ -2589,6 +2589,25 @@ +--- hotspot/src/os/bsd/vm/os_bsd.cpp 2012-08-10 09:24:18.000000000 -0700 ++++ hotspot/src/os/bsd/vm/os_bsd.cpp 2012-08-19 12:11:05.000000000 -0700 +@@ -2341,14 +2341,14 @@ + } + + void os::print_os_info_brief(outputStream* st) { +- st->print("Bsd"); ++ st->print("BSD"); + + os::Posix::print_uname_info(st); + } + + void os::print_os_info(outputStream* st) { + st->print("OS:"); +- st->print("Bsd"); ++ st->print("BSD"); + + os::Posix::print_uname_info(st); + +@@ -2357,10 +2357,6 @@ + os::Posix::print_load_average(st); + } + +-void os::pd_print_cpu_info(outputStream* st) { +- // Nothing to do for now. +-} +- + void os::print_memory_info(outputStream* st) { + + st->print("Memory:"); +@@ -2377,6 +2373,7 @@ + st->print("(" UINT64_FORMAT "k free)", + os::available_memory() >> 10); + #ifndef _ALLBSD_SOURCE ++ // FIXME: Make this work for *BSD + st->print(", swap " UINT64_FORMAT "k", + ((jlong)si.totalswap * si.mem_unit) >> 10); + st->print("(" UINT64_FORMAT "k free)", +@@ -2384,12 +2381,22 @@ + #endif + st->cr(); + ++ // FIXME: Make this work for *BSD + // meminfo + st->print("\n/proc/meminfo:\n"); + _print_ascii_file("/proc/meminfo", st); + st->cr(); + } + ++void os::pd_print_cpu_info(outputStream* st) { ++ // FIXME: Make this work for *BSD ++ st->print("\n/proc/cpuinfo:\n"); ++ if (!_print_ascii_file("/proc/cpuinfo", st)) { ++ st->print(" <Not Available>"); ++ } ++ st->cr(); ++} ++ + // Taken from /usr/include/bits/siginfo.h Supposed to be architecture specific + // but they're the same for all the bsd arch that we support + // and they're the same for solaris but there's no common place to put this. +@@ -2532,6 +2539,25 @@ len = strlen(buf); jrelib_p = buf + len; @@ -244,7 +886,7 @@ // Add the appropriate library subdir snprintf(jrelib_p, buflen-len, "/jre/lib"); if (0 != access(buf, F_OK)) { -@@ -2618,6 +2637,7 @@ +@@ -2561,6 +2587,7 @@ if (rp == NULL) return; } @@ -252,7 +894,7 @@ } } } -@@ -2874,7 +2894,11 @@ +@@ -2817,7 +2844,11 @@ } void os::free_memory(char *addr, size_t bytes, size_t alignment_hint) { @@ -264,8 +906,23 @@ } void os::numa_make_global(char *addr, size_t bytes) { ---- hotspot/src/os/bsd/vm/os_bsd.inline.hpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/os/bsd/vm/os_bsd.inline.hpp 2012-05-17 15:05:10.000000000 -0700 +--- hotspot/src/os/bsd/vm/os_bsd.hpp 2012-08-10 09:24:18.000000000 -0700 ++++ hotspot/src/os/bsd/vm/os_bsd.hpp 2012-08-19 12:11:05.000000000 -0700 +@@ -103,6 +103,12 @@ + + static bool hugetlbfs_sanity_check(bool warn, size_t page_size); + ++ static void print_full_memory_info(outputStream* st); ++#ifndef _ALLBSD_SOURCE ++ static void print_distro_info(outputStream* st); ++ static void print_libversion_info(outputStream* st); ++#endif ++ + public: + + static void init_thread_fpu_state(); +--- hotspot/src/os/bsd/vm/os_bsd.inline.hpp 2012-08-10 09:24:18.000000000 -0700 ++++ hotspot/src/os/bsd/vm/os_bsd.inline.hpp 2012-08-19 12:11:05.000000000 -0700 @@ -31,10 +31,22 @@ # include "atomic_bsd_x86.inline.hpp" # include "orderAccess_bsd_x86.inline.hpp" @@ -289,8 +946,8 @@ // System includes ---- hotspot/src/os/bsd/vm/thread_bsd.inline.hpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/os/bsd/vm/thread_bsd.inline.hpp 2012-05-17 15:05:32.000000000 -0700 +--- hotspot/src/os/bsd/vm/thread_bsd.inline.hpp 2012-08-10 09:24:18.000000000 -0700 ++++ hotspot/src/os/bsd/vm/thread_bsd.inline.hpp 2012-08-19 12:11:05.000000000 -0700 @@ -34,11 +34,26 @@ # include "orderAccess_bsd_x86.inline.hpp" # include "prefetch_bsd_x86.inline.hpp" @@ -318,8 +975,19 @@ // Contains inlined functions for class Thread and ThreadLocalStorage ---- hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp 2012-05-17 16:05:49.000000000 -0700 +--- hotspot/src/os_cpu/bsd_x86/vm/vmStructs_bsd_x86.hpp 2012-08-10 09:24:32.000000000 -0700 ++++ hotspot/src/os_cpu/bsd_x86/vm/vmStructs_bsd_x86.hpp 2012-08-19 12:11:05.000000000 -0700 +@@ -52,7 +52,7 @@ + /* Posix Thread IDs */ \ + /**********************/ \ + \ +- declare_unsigned_integer_type(thread_t) \ ++ declare_unsigned_integer_type(OS_THREAD_ID_TYPE) \ + declare_unsigned_integer_type(pthread_t) \ + \ + /* This must be the last entry, and must be present */ \ +--- hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp 2012-08-10 09:24:33.000000000 -0700 ++++ hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp 2012-08-19 12:11:05.000000000 -0700 @@ -24,7 +24,7 @@ */ @@ -329,8 +997,8 @@ # include <pthread_np.h> /* For pthread_attr_get_np */ #endif ---- hotspot/src/share/vm/runtime/atomic.cpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/share/vm/runtime/atomic.cpp 2012-05-16 19:03:34.000000000 -0700 +--- hotspot/src/share/vm/runtime/atomic.cpp 2012-08-10 09:27:53.000000000 -0700 ++++ hotspot/src/share/vm/runtime/atomic.cpp 2012-08-19 12:11:07.000000000 -0700 @@ -54,6 +54,12 @@ #ifdef TARGET_OS_ARCH_windows_x86 # include "atomic_windows_x86.inline.hpp" @@ -344,8 +1012,8 @@ #ifdef TARGET_OS_ARCH_linux_arm # include "atomic_linux_arm.inline.hpp" #endif ---- hotspot/src/share/vm/runtime/os.hpp 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/src/share/vm/runtime/os.hpp 2012-05-16 19:03:34.000000000 -0700 +--- hotspot/src/share/vm/runtime/os.hpp 2012-08-10 09:28:05.000000000 -0700 ++++ hotspot/src/share/vm/runtime/os.hpp 2012-08-19 12:11:07.000000000 -0700 @@ -30,6 +30,9 @@ #include "runtime/extendedPC.hpp" #include "runtime/handles.hpp" @@ -356,8 +1024,18 @@ #ifdef TARGET_OS_FAMILY_linux # include "jvm_linux.h" #endif ---- hotspot/test/compiler/5091921/Test7005594.sh 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/test/compiler/5091921/Test7005594.sh 2012-03-03 22:34:03.000000000 -0800 +@@ -694,8 +697,8 @@ + # include "os_windows.hpp" + #endif + #ifdef TARGET_OS_FAMILY_bsd +-# include "os_posix.hpp" + # include "os_bsd.hpp" ++# include "os_posix.hpp" + #endif + #ifdef TARGET_OS_ARCH_linux_x86 + # include "os_linux_x86.hpp" +--- hotspot/test/compiler/5091921/Test7005594.sh 2012-08-10 09:28:58.000000000 -0700 ++++ hotspot/test/compiler/5091921/Test7005594.sh 2012-08-19 12:11:07.000000000 -0700 @@ -71,6 +71,9 @@ # Windows/MKS MEM=`"$ROOTDIR/mksnt/sysinf" memory -v | grep "Total Physical Memory: " | sed 's/Total Physical Memory: *//g'` @@ -368,8 +1046,8 @@ else echo "Unable to determine amount of physical memory on the machine" fi ---- hotspot/test/gc/6941923/test6941923.sh 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/test/gc/6941923/test6941923.sh 2012-03-03 22:35:30.000000000 -0800 +--- hotspot/test/gc/6941923/test6941923.sh 2012-08-10 09:29:15.000000000 -0700 ++++ hotspot/test/gc/6941923/test6941923.sh 2012-08-19 12:11:08.000000000 -0700 @@ -9,7 +9,7 @@ ## skip on windows OS=`uname -s` @@ -379,8 +1057,8 @@ NULL=/dev/null PS=":" FS="/" ---- hotspot/test/runtime/7020373/Test7020373.sh 2012-05-26 23:29:10.000000000 -0700 -+++ hotspot/test/runtime/7020373/Test7020373.sh 2011-06-21 18:23:22.000000000 -0700 +--- hotspot/test/runtime/7020373/Test7020373.sh 2012-08-10 09:29:17.000000000 -0700 ++++ hotspot/test/runtime/7020373/Test7020373.sh 2012-08-19 12:11:08.000000000 -0700 @@ -32,7 +32,7 @@ # set platform-dependent variables OS=`uname -s` @@ -390,8 +1068,30 @@ NULL=/dev/null PS=":" FS="/" ---- jaxp/.hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ jaxp/.hgtags 2012-05-15 20:12:43.000000000 -0700 +--- hotspot/test/runtime/7110720/Test7110720.sh 2012-08-10 09:29:18.000000000 -0700 ++++ hotspot/test/runtime/7110720/Test7110720.sh 2012-08-19 12:11:08.000000000 -0700 +@@ -37,7 +37,7 @@ + # set platform-dependent variables + OS=`uname -s` + case "$OS" in +- SunOS | Linux ) ++ SunOS | Linux | *BSD ) + FS="/" + RM=/bin/rm + CP=/bin/cp +--- hotspot/test/runtime/7158800/Test7158800.sh 2012-08-10 09:29:19.000000000 -0700 ++++ hotspot/test/runtime/7158800/Test7158800.sh 2012-08-19 12:11:08.000000000 -0700 +@@ -46,7 +46,7 @@ + # set platform-dependent variables + OS=`uname -s` + case "$OS" in +- SunOS | Linux ) ++ SunOS | Linux | *BSD ) + NULL=/dev/null + PS=":" + FS="/" +--- jaxp/.hgtags 2012-08-10 09:35:08.000000000 -0700 ++++ jaxp/.hgtags 2012-08-19 12:04:20.000000000 -0700 @@ -123,6 +123,7 @@ bcd31fa1e3c6f51b4fdd427ef905188cdac57164 jdk7-b146 067fb18071e3872698f6218724958bd0cebf30a3 jdk7u1-b01 @@ -400,8 +1100,91 @@ 104ca42e1e7ca66b074a4619ce6420f15d8f454d jdk7u1-b02 64e323faadf65018c1ffc8bb9c97f7b664e87347 jdk7u1-b03 2256c20e66857f80cacda14ffdbc0979c929d7f8 jdk7u1-b04 ---- jaxws/.hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ jaxws/.hgtags 2012-05-15 20:13:50.000000000 -0700 +@@ -197,5 +198,4 @@ + 7403701aa75848ca2a7b297909908b858134e132 jdk7u6-b21 + fcf35906d1d88583878cd2e2d7c63dfba4e9f679 jdk7u6-b22 + 8824bcbfd7cd8059ededf70f1e7f2b06f02cb33f jdk7u6-b23 +-1365e7472a3b737dda4a73e06ad41718d667d9be jdk7u8-b01 +-0a313d4307930be3a64106b9b8c90f9342673aa0 jdk7u8-b02 ++378f719cfb9491b766cd9f7cd47ad7fa3503e141 jdk7u6-b24 +--- jaxp/src/com/sun/org/apache/xerces/internal/impl/XMLEntityManager.java 2012-08-10 09:36:39.000000000 -0700 ++++ jaxp/src/com/sun/org/apache/xerces/internal/impl/XMLEntityManager.java 2012-08-19 12:04:20.000000000 -0700 +@@ -602,7 +602,7 @@ + if (reader == null) { + stream = xmlInputSource.getByteStream(); + if (stream == null) { +- URL location = new URL(expandedSystemId); ++ URL location = new URL(escapeNonUSAscii(expandedSystemId)); + URLConnection connect = location.openConnection(); + if (!(connect instanceof HttpURLConnection)) { + stream = connect.getInputStream(); +@@ -2586,6 +2586,64 @@ + + } // fixURI(String):String + ++ /** ++ * Escape invalid URI characters. ++ * ++ * Passed a URI that contains invalid characters (like spaces, non-ASCII Unicode characters, and the like), ++ * this function percent encodes the invalid characters per the URI specification (i.e., as a sequence of ++ * %-encoded UTF-8 octets). ++ * ++ * N.B. There are two problems. If the URI contains a '%' character, that might be an indication that ++ * the URI has already been escaped by the author, or it might be an invalid '%'. In the former case, ++ * it's important not to escape it, or we'll wind up with invalid, doubly-escaped '%'s. In the latter, ++ * the URI is broken if we don't encode it. Similarly, a '#' character might be the start of a fragment ++ * identifier or it might be an invalid '#'. ++ * ++ * Given that the former is vastly more likely than the latter in each case (most users are familiar with ++ * the magic status of '%' and '#' and they occur relatively infrequently in filenames, and if the user parses ++ * a proper Java File, we will already have %-escaped the URI), we simply assume that %'s and #'s are legit. ++ * ++ * Very rarely, we may be wrong. If so, tell the user to fix the clearly broken URI. ++ */ ++ protected static String escapeNonUSAscii(String str) { ++ if (str == null) { ++ return str; ++ } ++ ++ // get UTF-8 bytes for the string ++ StringBuffer buffer = new StringBuffer(); ++ byte[] bytes = null; ++ byte b; ++ try { ++ bytes = str.getBytes("UTF-8"); ++ } catch (java.io.UnsupportedEncodingException e) { ++ // should never happen ++ return str; ++ } ++ int len = bytes.length; ++ int ch; ++ ++ // for each byte ++ for (int i = 0; i < len; i++) { ++ b = bytes[i]; ++ // for non-ascii character: make it positive, then escape ++ if (b < 0) { ++ ch = b + 256; ++ buffer.append('%'); ++ buffer.append(gHexChs[ch >> 4]); ++ buffer.append(gHexChs[ch & 0xf]); ++ } ++ else if (b != '%' && b != '#' && gNeedEscaping[b]) { ++ buffer.append('%'); ++ buffer.append(gAfterEscaping1[b]); ++ buffer.append(gAfterEscaping2[b]); ++ } ++ else { ++ buffer.append((char)b); ++ } ++ } ++ return buffer.toString(); ++ } + + // + // Package visible methods +--- jaxws/.hgtags 2012-08-10 09:46:32.000000000 -0700 ++++ jaxws/.hgtags 2012-08-19 12:01:22.000000000 -0700 @@ -123,6 +123,7 @@ 05469dd4c3662c454f8a019e492543add60795cc jdk7-b146 c01bfd68d0528bc88348813c4d75d7f5c62bc4e2 jdk7u1-b01 @@ -410,8 +1193,15 @@ 4c24f7019ce939a452154a83151294ad7da66a9d jdk7u1-b02 272778f529d11081f548f37fcd6a7aec0b11a8dd jdk7u1-b03 48b06a6e6f46e5bcd610f4bed57cd5067cf31f8c jdk7u1-b04 ---- jdk/.hgtags 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/.hgtags 2012-05-17 16:14:52.000000000 -0700 +@@ -197,5 +198,4 @@ + 55dcda93e8c8b5c3170def946de35dd0407eab59 jdk7u6-b21 + 0fec2efe2452aed9736da39add4c7f71be561838 jdk7u6-b22 + afb6d773328fa76cea65dc024a448cd931d111f2 jdk7u6-b23 +-55dcda93e8c8b5c3170def946de35dd0407eab59 jdk7u8-b01 +-c025e953f655b375f27f8f94493ceeb43ef1d979 jdk7u8-b02 ++b8b85e62d2c5347df8cf2e825e51e3de178508ea jdk7u6-b24 +--- jdk/.hgtags 2012-08-10 10:21:29.000000000 -0700 ++++ jdk/.hgtags 2012-08-19 12:39:46.000000000 -0700 @@ -123,6 +123,7 @@ 539e576793a8e64aaf160e0d6ab0b9723cd0bef0 jdk7-b146 69e973991866c948cf1808b06884ef2d28b64fcb jdk7u1-b01 @@ -420,8 +1210,15 @@ 2baf612764d215e6f3a5b48533f74c6924ac98d7 jdk7u1-b02 a4781b6d9cfb6901452579adee17c9a17c1b584c jdk7u1-b03 b223ed9a5fdf8ce3af42adfa8815975811d70eae jdk7u1-b04 ---- jdk/make/com/sun/nio/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/nio/Makefile 2012-05-17 16:18:00.000000000 -0700 +@@ -197,5 +198,4 @@ + 243717d7fe9589148951ffb5551264af0e446314 jdk7u6-b21 + d78f2b600d393f45d6ace8ca0f29ad677624a775 jdk7u6-b22 + 0ae89e53f5300da1961984a7d81c220c7cf717d7 jdk7u6-b23 +-df945ef30444adf08f3ef14b0c49c8bda6dda587 jdk7u8-b01 +-dd1e513c05b8b8c8402e9ecf9c0d5bdbebb1a089 jdk7u8-b02 ++1c775da998735711853cfe1ae1d6baddc5f12a66 jdk7u6-b24 +--- jdk/make/com/sun/nio/Makefile 2012-08-10 10:21:31.000000000 -0700 ++++ jdk/make/com/sun/nio/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -31,11 +31,18 @@ include $(BUILDDIR)/common/Defs.gmk @@ -442,8 +1239,8 @@ all build clean clobber:: $(SUBDIRS-loop) ---- jdk/make/com/sun/nio/sctp/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/nio/sctp/Makefile 2011-04-22 23:08:15.000000000 -0700 +--- jdk/make/com/sun/nio/sctp/Makefile 2012-08-10 10:21:31.000000000 -0700 ++++ jdk/make/com/sun/nio/sctp/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -59,15 +59,11 @@ -I$(PLATFORM_SRC)/native/java/net \ -I$(CLASSHDRDIR)/../../../../java/java.nio/nio/CClassHeaders @@ -462,8 +1259,8 @@ else # windows include $(BUILDDIR)/common/Classes.gmk ---- jdk/make/com/sun/security/auth/module/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/security/auth/module/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/com/sun/security/auth/module/Makefile 2012-08-10 10:21:32.000000000 -0700 ++++ jdk/make/com/sun/security/auth/module/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -67,7 +67,7 @@ include FILES_c_solaris.gmk endif # solaris @@ -473,8 +1270,8 @@ LIBRARY = jaas_unix include FILES_export_unix.gmk include FILES_c_unix.gmk ---- jdk/make/com/sun/tools/attach/Exportedfiles.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/tools/attach/Exportedfiles.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/com/sun/tools/attach/Exportedfiles.gmk 2012-08-10 10:21:32.000000000 -0700 ++++ jdk/make/com/sun/tools/attach/Exportedfiles.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -43,7 +43,7 @@ sun/tools/attach/LinuxVirtualMachine.java endif @@ -484,8 +1281,8 @@ FILES_export = \ sun/tools/attach/BsdVirtualMachine.java endif ---- jdk/make/com/sun/tools/attach/FILES_c.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/tools/attach/FILES_c.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/com/sun/tools/attach/FILES_c.gmk 2012-08-10 10:21:32.000000000 -0700 ++++ jdk/make/com/sun/tools/attach/FILES_c.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -39,7 +39,7 @@ LinuxVirtualMachine.c endif @@ -495,8 +1292,8 @@ FILES_c = \ BsdVirtualMachine.c endif ---- jdk/make/com/sun/tools/attach/FILES_java.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/tools/attach/FILES_java.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/com/sun/tools/attach/FILES_java.gmk 2012-08-10 10:21:32.000000000 -0700 ++++ jdk/make/com/sun/tools/attach/FILES_java.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -43,7 +43,7 @@ sun/tools/attach/LinuxAttachProvider.java endif @@ -506,9 +1303,9 @@ FILES_java += \ sun/tools/attach/BsdAttachProvider.java endif ---- jdk/make/com/sun/tools/attach/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/com/sun/tools/attach/Makefile 2012-05-17 16:18:00.000000000 -0700 -@@ -36,7 +36,7 @@ +--- jdk/make/com/sun/tools/attach/Makefile 2012-08-10 10:21:32.000000000 -0700 ++++ jdk/make/com/sun/tools/attach/Makefile 2012-08-19 12:39:46.000000000 -0700 +@@ -38,7 +38,7 @@ ifeq ($(PLATFORM), linux) FILES_m = mapfile-linux endif @@ -517,7 +1314,7 @@ FILES_m = mapfile-bsd endif include $(BUILDDIR)/common/Mapfile-vers.gmk -@@ -55,7 +55,7 @@ +@@ -57,7 +57,7 @@ EXTRA_LIBS += psapi.lib endif @@ -527,10 +1324,10 @@ else vpath %.c $(PLATFORM_SRC)/native/sun/tools/attach --- jdk/make/common/Defs-bsd.gmk 1969-12-31 16:00:00.000000000 -0800 -+++ jdk/make/common/Defs-bsd.gmk 2012-05-22 22:28:15.000000000 -0700 -@@ -0,0 +1,480 @@ ++++ jdk/make/common/Defs-bsd.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -0,0 +1,527 @@ +# -+# Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it @@ -614,55 +1411,90 @@ +CC_OBJECT_OUTPUT_FLAG = -o #trailing blank required! +CC_PROGRAM_OUTPUT_FLAG = -o #trailing blank required! + -+# Default OBJCOPY comes from GNU Binutils on BSD: -+DEF_OBJCOPY=/usr/bin/objcopy -+ifdef CROSS_COMPILE_ARCH -+ # don't try to generate .debuginfo files when cross compiling -+ _JUNK_ := $(shell \ -+ echo >&2 "INFO: cross compiling for ARCH $(CROSS_COMPILE_ARCH)," \ -+ "skipping .debuginfo generation.") -+ OBJCOPY= -+else -+ OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY)) -+ ifneq ($(ALT_OBJCOPY),) -+ _JUNK_ := $(shell echo >&2 "INFO: ALT_OBJCOPY=$(ALT_OBJCOPY)") -+ # disable .debuginfo support by setting ALT_OBJCOPY to a non-existent path -+ OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY)) -+ endif -+endif -+ -+ifdef LIBRARY_SUPPORTS_FULL_DEBUG_SYMBOLS -+# The setting of OBJCOPY above enables the JDK build to import -+# .debuginfo files from the HotSpot build. However, adding FDS -+# support to the JDK build will occur in phases so a different -+# make variable is used to indicate that a particular library -+# supports FDS. ++# The Full Debug Symbols (FDS) default for VARIANT == OPT builds is ++# enabled with debug info files ZIP'ed to save space. For VARIANT != ++# OPT builds, FDS is always enabled, after all a debug build without ++# debug info isn't very useful. The ZIP_DEBUGINFO_FILES option only has ++# meaning when FDS is enabled. ++# ++# If you invoke a build with FULL_DEBUG_SYMBOLS=0, then FDS will be ++# disabled for a VARIANT == OPT build. ++# ++# Note: Use of a different variable name for the FDS override option ++# versus the FDS enabled check is intentional (FULL_DEBUG_SYMBOLS ++# versus ENABLE_FULL_DEBUG_SYMBOLS). For auto build systems that pass ++# in options via environment variables, use of distinct variables ++# prevents strange behaviours. For example, in a VARIANT != OPT build, ++# the FULL_DEBUG_SYMBOLS environment variable will be 0, but the ++# ENABLE_FULL_DEBUG_SYMBOLS make variable will be 1. If the same ++# variable name is used, then different values can be picked up by ++# different parts of the build. Just to be clear, we only need two ++# variable names because the incoming option value can be overridden ++# in some situations, e.g., a VARIANT != OPT build. + -+ifeq ($(OBJCOPY),) -+ _JUNK_ := $(shell \ -+ echo >&2 "INFO: no objcopy cmd found so cannot create .debuginfo files.") ++ifeq ($(VARIANT), OPT) ++ FULL_DEBUG_SYMBOLS ?= 1 ++ ENABLE_FULL_DEBUG_SYMBOLS = $(FULL_DEBUG_SYMBOLS) +else -+ _JUNK_ := $(shell \ -+ echo >&2 "INFO: $(OBJCOPY) cmd found so will create .debuginfo files.") -+ -+ # Library stripping policies for .debuginfo configs: -+ # all_strip - strips everything from the library -+ # min_strip - strips most stuff from the library; leaves minimum symbols -+ # no_strip - does not strip the library at all -+ # -+ # Oracle security policy requires "all_strip". A waiver was granted on -+ # 2011.09.01 that permits using "min_strip" in the Java JDK and Java JRE. -+ # -+ DEF_STRIP_POLICY="min_strip" -+ ifeq ($(ALT_STRIP_POLICY),) -+ STRIP_POLICY=$(DEF_STRIP_POLICY) ++ # debug variants always get Full Debug Symbols (if available) ++ ENABLE_FULL_DEBUG_SYMBOLS = 1 ++endif ++_JUNK_ := $(shell \ ++ echo >&2 "INFO: ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS)") ++# since objcopy is optional, we set ZIP_DEBUGINFO_FILES later ++ ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ # Default OBJCOPY comes from GNU Binutils on BSD: ++ DEF_OBJCOPY=/usr/bin/objcopy ++ ifdef CROSS_COMPILE_ARCH ++ # don't try to generate .debuginfo files when cross compiling ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: cross compiling for ARCH $(CROSS_COMPILE_ARCH)," \ ++ "skipping .debuginfo generation.") ++ OBJCOPY= + else -+ STRIP_POLICY=$(ALT_STRIP_POLICY) ++ OBJCOPY=$(shell test -x $(DEF_OBJCOPY) && echo $(DEF_OBJCOPY)) ++ ifneq ($(ALT_OBJCOPY),) ++ _JUNK_ := $(shell echo >&2 "INFO: ALT_OBJCOPY=$(ALT_OBJCOPY)") ++ # disable .debuginfo support by setting ALT_OBJCOPY to a non-existent path ++ OBJCOPY=$(shell test -x $(ALT_OBJCOPY) && echo $(ALT_OBJCOPY)) ++ endif + endif + -+ _JUNK_ := $(shell \ -+ echo >&2 "INFO: STRIP_POLICY=$(STRIP_POLICY)") -+endif ++ # Setting ENABLE_FULL_DEBUG_SYMBOLS=1 (and OBJCOPY) above enables the ++ # JDK build to import .debuginfo or .diz files from the HotSpot build. ++ # However, adding FDS support to the JDK build will occur in phases ++ # so a different make variable (LIBRARY_SUPPORTS_FULL_DEBUG_SYMBOLS ++ # and PROGRAM_SUPPORTS_FULL_DEBUG_SYMBOLS) is used to indicate that a ++ # particular library or program supports FDS. ++ ++ ifeq ($(OBJCOPY),) ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: no objcopy cmd found so cannot create .debuginfo files.") ++ ENABLE_FULL_DEBUG_SYMBOLS=0 ++ else ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: $(OBJCOPY) cmd found so will create .debuginfo files.") ++ ++ # Library stripping policies for .debuginfo configs: ++ # all_strip - strips everything from the library ++ # min_strip - strips most stuff from the library; leaves minimum symbols ++ # no_strip - does not strip the library at all ++ # ++ # Oracle security policy requires "all_strip". A waiver was granted on ++ # 2011.09.01 that permits using "min_strip" in the Java JDK and Java JRE. ++ # ++ # Currently, STRIP_POLICY is only used when Full Debug Symbols is enabled. ++ STRIP_POLICY ?= min_strip ++ ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: STRIP_POLICY=$(STRIP_POLICY)") ++ ++ ZIP_DEBUGINFO_FILES ?= 1 ++ ++ _JUNK_ := $(shell \ ++ echo >&2 "INFO: ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES)") ++ endif +endif + +# @@ -763,6 +1595,17 @@ + CFLAGS_REQUIRED += $(DEBUG_FLAG) +endif + ++# If Full Debug Symbols is enabled, then we want the same debug and ++# optimization flags as used by FASTDEBUG. ++# ++ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(LIBRARY_SUPPORTS_FULL_DEBUG_SYMBOLS),1) ++ ifeq ($(VARIANT), OPT) ++ CC_OPT = $(DEBUG_FLAG) $(CC_OPT/$(FASTDEBUG_OPTIMIZATION_LEVEL)) ++ endif ++ endif ++endif ++ +CFLAGS_OPT = $(CC_OPT) +CFLAGS_DBG = $(DEBUG_FLAG) +CFLAGS_COMMON += $(CFLAGS_REQUIRED) @@ -994,6 +1837,7 @@ +HOTSPOT_SALIB_PATH = $(HOTSPOT_IMPORT_PATH)/jre/lib/$(LIBARCH) +SALIB_NAME = $(LIB_PREFIX)saproc.$(LIBRARY_SUFFIX) +SA_DEBUGINFO_NAME = $(LIB_PREFIX)saproc.debuginfo ++SA_DIZ_NAME = $(LIB_PREFIX)saproc.diz + +# The JDI - Serviceability Agent binding is not currently supported +# on ia64. @@ -1009,9 +1853,9 @@ + OTHER_CXXFLAGS += -I$(OPENWIN_HOME)/include + OTHER_CPPFLAGS += -I$(OPENWIN_HOME)/include +endif ---- jdk/make/common/Defs-linux.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Defs-linux.gmk 2012-05-17 16:14:53.000000000 -0700 -@@ -383,6 +383,7 @@ +--- jdk/make/common/Defs-linux.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Defs-linux.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -429,6 +429,7 @@ override LIBDL = -ldl override MOOT_PRIORITIES = true override NO_INTERRUPTIBLE_IO = true @@ -1019,9 +1863,9 @@ ifeq ($(ARCH), amd64) override OPENWIN_LIB = $(OPENWIN_HOME)/lib64 else ---- jdk/make/common/Defs-solaris.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Defs-solaris.gmk 2012-05-17 16:14:53.000000000 -0700 -@@ -716,6 +716,9 @@ +--- jdk/make/common/Defs-solaris.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Defs-solaris.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -753,6 +753,9 @@ # Network Services library LIBNSL = -lnsl @@ -1031,8 +1875,8 @@ # service configuration facility library LIBSCF = -lscf ---- jdk/make/common/Defs.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Defs.gmk 2012-05-22 22:40:52.000000000 -0700 +--- jdk/make/common/Defs.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Defs.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -179,15 +179,15 @@ ifdef ALT_FREETYPE_LIB_PATH @@ -1074,7 +1918,7 @@ endif # PROGRAM LDLIBS_COMMON += $(EXTRA_LIBS) -@@ -398,7 +402,7 @@ +@@ -399,7 +403,7 @@ # We define an intermediate variable for Java files because # we use its value later to help define $SOURCEPATH @@ -1083,8 +1927,25 @@ VPATH0.java = $(subst $(ONESPACE),:,$(GENSRCDIR) $(call JavaSrcDirList,,classes)) else VPATH0.java = $(GENSRCDIR)$(CLASSPATH_SEPARATOR)$(PLATFORM_SRC)/classes$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/classes ---- jdk/make/common/Mapfile-vers.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Mapfile-vers.gmk 2011-08-02 23:11:42.000000000 -0700 +--- jdk/make/common/Library.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Library.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -299,8 +299,12 @@ + ifeq ($(PLATFORM), solaris) + $(STRIP) -x $@ + else +- # assume Linux +- $(STRIP) -g $@ ++ ifeq ($(PLATFORM), linux) ++ $(STRIP) -g $@ ++ else ++ # assume BSD ++ $(STRIP) -S $@ ++ endif + endif + # implied else here is no stripping at all + endif +--- jdk/make/common/Mapfile-vers.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Mapfile-vers.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -76,7 +76,7 @@ endif # PLATFORM @@ -1094,8 +1955,8 @@ ifeq ($(VARIANT), OPT) # OPT build MUST have a mapfile? ---- jdk/make/common/Program.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Program.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/common/Program.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Program.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -95,6 +95,17 @@ endif # SYSTEM_ZLIB endif # PLATFORM @@ -1114,7 +1975,7 @@ ifneq (,$(findstring $(PLATFORM), linux solaris)) # UNIX systems LDFLAGS += -L $(LIBDIR)/$(LIBARCH)/jli OTHER_LDLIBS += -ljli -@@ -214,6 +225,11 @@ +@@ -227,6 +238,11 @@ INFO_PLIST_FILE= endif # MACOSX @@ -1126,7 +1987,22 @@ # # This rule only applies on unix. It supports quantify and its ilk. # -@@ -272,7 +288,9 @@ +@@ -281,8 +297,12 @@ + ifeq ($(PLATFORM), solaris) + $(STRIP) -x $@ + else +- # assume Linux +- $(STRIP) -g $@ ++ ifeq ($(PLATFORM), linux) ++ $(STRIP) -g $@ ++ else ++ # assume BSD ++ $(STRIP) -S $@ ++ endif + endif + # implied else here is no stripping at all + endif +@@ -350,7 +370,9 @@ ifneq ($(PLATFORM), windows) @@ -1137,7 +2013,7 @@ endif #PLATFORM ifeq ($(HAVE_GETHRTIME),true) -@@ -282,12 +300,10 @@ +@@ -360,12 +382,10 @@ OTHER_INCLUDES += -I$(LAUNCHER_SHARE_SRC)/bin -I$(LAUNCHER_PLATFORM_SRC)/bin ifeq ($(PLATFORM), macosx) OTHER_INCLUDES += -I$(LAUNCHER_SOLARIS_PLATFORM_SRC)/bin @@ -1153,9 +2029,9 @@ OTHER_CPPFLAGS += -DPROGNAME='"$(PROGRAM)"' VERSION_DEFINES += -DFULL_VERSION='"$(FULL_VERSION)"' ---- jdk/make/common/Release.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Release.gmk 2012-05-17 16:18:00.000000000 -0700 -@@ -177,6 +177,12 @@ +--- jdk/make/common/Release.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Release.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -178,6 +178,12 @@ JA_DIRNAME=ja_JP.UTF-8 endif # linux @@ -1168,7 +2044,7 @@ define copy-man-pages $(MKDIR) -p $1/man/man1 for manbase in $(MANBASEDIRS:%=%/$(MAN1SUBDIR)) ; do \ -@@ -980,6 +986,12 @@ +@@ -983,6 +989,12 @@ FILES_launcher = $(wildcard $(SHARE_SRC)/bin/*) \ $(wildcard $(PLATFORM_SRC)/bin/java_md*) @@ -1181,7 +2057,7 @@ # Standard jdk image initial-image-jdk:: initial-image-jdk-setup \ initial-image-jdk-db \ -@@ -1067,7 +1079,7 @@ +@@ -1070,7 +1082,7 @@ @# So for Linux, make use of the -T option (like Solaris' -I option) of @# obtaining the list of files from a file. MKS tar has no such option. @@ -1190,7 +2066,7 @@ for d in $(SOURCE_DIRS); do \ $(RM) $(ABS_TEMPDIR)/src-files.list; \ ($(CD) $$d && \ -@@ -1080,7 +1092,7 @@ +@@ -1083,7 +1095,7 @@ done ; \ ) ; \ if [ -f $(ABS_TEMPDIR)/src-files.list ] ; then \ @@ -1199,8 +2075,8 @@ | ($(CD) $(JDK_IMAGE_DIR)/src && $(TAR) xf -); \ fi; \ done ---- jdk/make/common/Rules.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/Rules.gmk 2012-05-20 10:20:11.000000000 -0700 +--- jdk/make/common/Rules.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/Rules.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -51,7 +51,7 @@ # # All source tree areas for java/properties files (a few may be closed) @@ -1219,8 +2095,8 @@ # TODO(cpc): need to document why this is necessary... $(CLASSDESTDIR)/%.class: $(JDK_TOPDIR)/src/macosx/classes/%.java @$(add-java-file) ---- jdk/make/common/shared/Compiler-gcc.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/shared/Compiler-gcc.gmk 2012-05-20 11:23:26.000000000 -0700 +--- jdk/make/common/shared/Compiler-gcc.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/shared/Compiler-gcc.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -72,6 +72,21 @@ endif @@ -1244,7 +2120,7 @@ # Settings specific to Solaris --- jdk/make/common/shared/Defs-bsd.gmk 1969-12-31 16:00:00.000000000 -0800 -+++ jdk/make/common/shared/Defs-bsd.gmk 2012-05-22 19:42:36.000000000 -0700 ++++ jdk/make/common/shared/Defs-bsd.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -0,0 +1,225 @@ +# +# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. @@ -1471,8 +2347,8 @@ +endef +endif + ---- jdk/make/common/shared/Defs-utils.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/shared/Defs-utils.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/common/shared/Defs-utils.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/shared/Defs-utils.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -74,6 +74,13 @@ UTILS_DEVTOOL_PATH=$(DEVTOOLS_PATH) endif @@ -1523,8 +2399,8 @@ + UNZIP = $(UTILS_DEVTOOL_PATH)unzip + endif +endif ---- jdk/make/common/shared/Defs-versions.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/shared/Defs-versions.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/common/shared/Defs-versions.gmk 2012-08-10 10:21:33.000000000 -0700 ++++ jdk/make/common/shared/Defs-versions.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -44,6 +44,11 @@ override CC_VERSION = gcc endif @@ -1551,8 +2427,8 @@ # Mac specific ifeq ($(PLATFORM), macosx) REQUIRED_OS_NAME = Darwin ---- jdk/make/common/shared/Defs.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/shared/Defs.gmk 2012-05-20 10:20:50.000000000 -0700 +--- jdk/make/common/shared/Defs.gmk 2012-08-10 10:21:34.000000000 -0700 ++++ jdk/make/common/shared/Defs.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -181,7 +181,7 @@ # platform and shared sources/headers. This is mainly useful for the # Mac OS X build, which pulls its platform sources from the solaris and/or @@ -1562,8 +2438,8 @@ define JavaSrcDirList $(JAVA_SRCDIR_LIST:%=$1$(JDK_TOPDIR)/%/$2) endef ---- jdk/make/common/shared/Platform.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/common/shared/Platform.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/common/shared/Platform.gmk 2012-08-10 10:21:34.000000000 -0700 ++++ jdk/make/common/shared/Platform.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -298,6 +298,85 @@ # How much RAM does this machine have: endif @@ -1650,8 +2526,8 @@ # Windows with and without CYGWIN will be slightly different ifeq ($(SYSTEM_UNAME), Windows_NT) PLATFORM = windows ---- jdk/make/java/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/Makefile 2012-05-17 16:14:53.000000000 -0700 +--- jdk/make/java/Makefile 2012-08-10 10:21:34.000000000 -0700 ++++ jdk/make/java/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -53,7 +53,7 @@ endif endif # PLATFORM @@ -1661,9 +2537,9 @@ SUBDIRS += jexec endif # PLATFORM ---- jdk/make/java/instrument/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/instrument/Makefile 2012-05-17 16:18:00.000000000 -0700 -@@ -102,12 +102,24 @@ +--- jdk/make/java/instrument/Makefile 2012-08-10 10:21:34.000000000 -0700 ++++ jdk/make/java/instrument/Makefile 2012-08-19 12:39:46.000000000 -0700 +@@ -104,12 +104,24 @@ # equivalent of strcasecmp is stricmp on Windows CPPFLAGS_COMMON += -Dstrcasecmp=stricmp else @@ -1693,8 +2569,8 @@ ifeq ($(SYSTEM_ZLIB), true) OTHER_LDLIBS += -lz endif ---- jdk/make/java/java/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/java/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/java/java/Makefile 2012-08-10 10:21:35.000000000 -0700 ++++ jdk/make/java/java/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -175,9 +175,11 @@ # ifneq ($(PLATFORM), windows) @@ -1707,8 +2583,58 @@ ifeq ($(HAVE_ALTZONE),true) OTHER_CPPFLAGS += -DHAVE_ALTZONE ---- jdk/make/java/jli/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/jli/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/java/java/genlocales.gmk 2012-08-10 10:21:35.000000000 -0700 ++++ jdk/make/java/java/genlocales.gmk 2012-08-19 12:39:46.000000000 -0700 +@@ -93,17 +93,43 @@ + + else + ++ifeq ($(PLATFORM), bsd) ++ + $(LocaleDataMetaInfo_Dest):$(LocaleDataMetaInfo_Src) $(LOCALEGEN_SH) + @$(RM) $@.tmp.euro $@.tmp.noneuro; + @$(prep-target) +- @$(ECHO) $(subst .properties,'\n',$(Euro_Resources_properties)) > $@.tmp.euro; +- @$(ECHO) $(subst .java,'\n',$(Euro_Resources_java)) >> $@.tmp.euro; +- @$(ECHO) $(subst .properties,'\n',$(NonEuro_Resources_properties)) > $@.tmp.noneuro; +- @$(ECHO) $(subst .java,'\n',$(NonEuro_Resources_java)) >> $@.tmp.noneuro; ++ @$(ECHO) $(Euro_Resources_properties) | $(SED) -e s@.properties@'\ ++'@g > $@.tmp.euro; ++ @$(ECHO) $(Euro_Resources_java) | $(SED) -e s@.java@'\ ++'@g >> $@.tmp.euro; ++ @$(ECHO) $(NonEuro_Resources_properties) | $(SED) -e s@.properties@'\ ++'@g > $@.tmp.noneuro; ++ @$(ECHO) $(NonEuro_Resources_java) | $(SED) -e s@.java@'\ ++'@g >> $@.tmp.noneuro; + NAWK="$(NAWK)" SED="$(SED)" SORT="$(SORT)" \ + $(SH) $(LOCALEGEN_SH) $(RESOURCE_NAMES) $@.tmp.euro \ + $@.tmp.noneuro $< $@ + @$(RM) $@.tmp.euro $@.tmp.noneuro; ++ ++else ++ ++$(LocaleDataMetaInfo_Dest):$(LocaleDataMetaInfo_Src) $(LOCALEGEN_SH) ++ @$(RM) $@.tmp.euro $@.tmp.noneuro; ++ @$(prep-target) ++ @$(ECHO) $(Euro_Resources_properties) | $(SED) -e s@.properties@'\ ++'@g > $@.tmp.euro; ++ @$(ECHO) $(Euro_Resources_java) | $(SED) -e s@.java@'\ ++'@g >> $@.tmp.euro; ++ @$(ECHO) $(NonEuro_Resources_properties) | $(SED) -e s@.properties@'\ ++'@g > $@.tmp.noneuro; ++ @$(ECHO) $(NonEuro_Resources_java) | $(SED) -e s@.java@'\ ++'@g >> $@.tmp.noneuro; ++ NAWK="$(NAWK)" SED="$(SED)" SORT="$(SORT)" \ ++ $(SH) $(LOCALEGEN_SH) $(RESOURCE_NAMES) $@.tmp.euro \ ++ $@.tmp.noneuro $< $@ ++ @$(RM) $@.tmp.euro $@.tmp.noneuro; ++endif ++ + endif + + genlocales : $(LocaleDataMetaInfo_Dest) +--- jdk/make/java/jli/Makefile 2012-08-10 10:21:36.000000000 -0700 ++++ jdk/make/java/jli/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -116,9 +116,9 @@ LIBARCH_DEFINES += -DLIBARCH64NAME='"$(LIBARCH64)"' endif # PLATFORM @@ -1730,8 +2656,8 @@ ifeq ($(USE_PTHREADS),true) LDLIBS += -lpthread endif # USE_PTHREADS ---- jdk/make/java/net/FILES_c.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/net/FILES_c.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/java/net/FILES_c.gmk 2012-08-10 10:21:36.000000000 -0700 ++++ jdk/make/java/net/FILES_c.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -47,6 +47,10 @@ FILES_c += bsd_close.c endif @@ -1743,8 +2669,8 @@ ifeq ($(PLATFORM), windows) FILES_c += TwoStacksPlainSocketImpl.c FILES_c += DualStackPlainSocketImpl.c ---- jdk/make/java/net/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/net/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/java/net/Makefile 2012-08-10 10:21:36.000000000 -0700 ++++ jdk/make/java/net/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -91,7 +91,7 @@ include $(BUILDDIR)/common/Library.gmk @@ -1754,8 +2680,8 @@ ifdef DONT_ENABLE_IPV6 OTHER_CFLAGS += -DDONT_ENABLE_IPV6 endif ---- jdk/make/java/nio/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/nio/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/java/nio/Makefile 2012-08-10 10:21:36.000000000 -0700 ++++ jdk/make/java/nio/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -260,7 +260,7 @@ sun/nio/fs/UnixConstants.java endif # PLATFORM = linux @@ -1802,9 +2728,29 @@ FILES_m = mapfile-bsd endif include $(BUILDDIR)/common/Mapfile-vers.gmk ---- jdk/make/java/npt/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/npt/Makefile 2012-05-17 16:18:00.000000000 -0700 -@@ -72,6 +72,14 @@ +--- jdk/make/java/nio/mapfile-linux 2012-08-10 10:21:37.000000000 -0700 ++++ jdk/make/java/nio/mapfile-linux 2012-08-19 12:39:46.000000000 -0700 +@@ -88,7 +88,6 @@ + Java_sun_nio_ch_IOUtil_drain; + Java_sun_nio_ch_IOUtil_fdVal; + Java_sun_nio_ch_IOUtil_initIDs; +- Java_sun_nio_ch_IOUtil_iovMax; + Java_sun_nio_ch_IOUtil_makePipe; + Java_sun_nio_ch_IOUtil_randomBytes; + Java_sun_nio_ch_IOUtil_setfdVal; +--- jdk/make/java/nio/mapfile-solaris 2012-08-10 10:21:37.000000000 -0700 ++++ jdk/make/java/nio/mapfile-solaris 2012-08-19 12:39:46.000000000 -0700 +@@ -76,7 +76,6 @@ + Java_sun_nio_ch_IOUtil_drain; + Java_sun_nio_ch_IOUtil_fdVal; + Java_sun_nio_ch_IOUtil_initIDs; +- Java_sun_nio_ch_IOUtil_iovMax; + Java_sun_nio_ch_IOUtil_makePipe; + Java_sun_nio_ch_IOUtil_randomBytes; + Java_sun_nio_ch_IOUtil_setfdVal; +--- jdk/make/java/npt/Makefile 2012-08-10 10:21:37.000000000 -0700 ++++ jdk/make/java/npt/Makefile 2012-08-19 12:39:46.000000000 -0700 +@@ -74,6 +74,14 @@ OTHER_LDLIBS += -liconv endif @@ -1819,8 +2765,8 @@ # # Add to ambient vpath so we pick up the library files # ---- jdk/make/java/redist/fonts/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/java/redist/fonts/Makefile 2011-04-22 23:08:16.000000000 -0700 +--- jdk/make/java/redist/fonts/Makefile 2012-08-10 10:21:37.000000000 -0700 ++++ jdk/make/java/redist/fonts/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -42,7 +42,7 @@ $(LIBDIR)/fonts/LucidaSansRegular.ttf \ $(LIBDIR)/fonts/LucidaSansDemiBold.ttf \ @@ -1848,8 +2794,8 @@ all build : $(INTERNAL_IMPORT_LIST) ---- jdk/make/javax/sound/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/javax/sound/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/javax/sound/Makefile 2012-08-10 10:21:40.000000000 -0700 ++++ jdk/make/javax/sound/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -111,6 +111,21 @@ #MXSPP_ADD = $(PLATFORM)-$(ARCH)/ endif # PLATFORM linux @@ -1872,8 +2818,8 @@ ifeq ($(PLATFORM), macosx) CPPFLAGS += -DUSE_PORTS=TRUE \ -DUSE_DAUDIO=TRUE \ ---- jdk/make/javax/sound/SoundDefs.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/javax/sound/SoundDefs.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/javax/sound/SoundDefs.gmk 2012-08-10 10:21:40.000000000 -0700 ++++ jdk/make/javax/sound/SoundDefs.gmk 2012-08-19 12:39:46.000000000 -0700 @@ -40,6 +40,10 @@ CPPFLAGS += -DX_PLATFORM=X_LINUX endif # PLATFORM linux @@ -1885,8 +2831,8 @@ ifeq ($(PLATFORM), macosx) CPPFLAGS += -DX_PLATFORM=X_MACOSX endif # PLATFORM macosx ---- jdk/make/javax/sound/jsoundalsa/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/javax/sound/jsoundalsa/Makefile 2011-04-22 23:08:16.000000000 -0700 +--- jdk/make/javax/sound/jsoundalsa/Makefile 2012-08-10 10:21:40.000000000 -0700 ++++ jdk/make/javax/sound/jsoundalsa/Makefile 2012-08-19 12:39:46.000000000 -0700 @@ -51,6 +51,7 @@ $(PORTFILES_c) @@ -1922,8 +2868,8 @@ $(MIDIFILES_export) \ $(PORTFILES_export) --LDFLAGS += -lasound -+LDFLAGS += -L$(ALSA_LIB_PATH) -lasound +-OTHER_LDLIBS += -lasound ++OTHER_LDLIBS += -L$(ALSA_LIB_PATH) -lasound CPPFLAGS += \ -DUSE_DAUDIO=TRUE \ @@ -1937,9 +2883,9 @@ # # Add to the ambient VPATH. ---- jdk/make/jpda/transport/socket/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/jpda/transport/socket/Makefile 2012-05-17 16:18:00.000000000 -0700 -@@ -36,6 +36,11 @@ +--- jdk/make/jpda/transport/socket/Makefile 2012-08-10 10:21:40.000000000 -0700 ++++ jdk/make/jpda/transport/socket/Makefile 2012-08-19 12:39:46.000000000 -0700 +@@ -38,6 +38,11 @@ include $(BUILDDIR)/common/Defs.gmk @@ -1951,8 +2897,8 @@ ifeq ($(PLATFORM), linux) OTHER_LDLIBS += $(LIBNSL) $(LIBSOCKET) -lpthread endif ---- jdk/make/sun/awt/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/awt/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/sun/awt/Makefile 2012-08-10 10:21:49.000000000 -0700 ++++ jdk/make/sun/awt/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -125,6 +125,13 @@ FILES_c += initIDs.c @@ -2010,8 +2956,8 @@ LDFLAGS += -L$(OPENWIN_LIB) endif ---- jdk/make/sun/awt/mawt.gmk 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/awt/mawt.gmk 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/sun/awt/mawt.gmk 2012-08-10 10:21:49.000000000 -0700 ++++ jdk/make/sun/awt/mawt.gmk 2012-08-19 12:39:47.000000000 -0700 @@ -169,7 +169,7 @@ OTHER_LDLIBS = -lXt -lXext $(LIBXTST) $(LIBXMU) -lX11 -lXi endif @@ -2044,9 +2990,18 @@ ifeq ($(PLATFORM), macosx)) CPPFLAGS += -I$(OPENWIN_HOME)/include/X11/extensions \ -I$(OPENWIN_HOME)/include ---- jdk/make/sun/font/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/font/Makefile 2012-05-17 16:18:00.000000000 -0700 -@@ -172,7 +172,7 @@ +--- jdk/make/sun/font/Makefile 2012-08-10 10:21:50.000000000 -0700 ++++ jdk/make/sun/font/Makefile 2012-08-19 12:39:47.000000000 -0700 +@@ -91,7 +91,7 @@ + endif # PLATFORM + + # Turn off aliasing with GCC for ExtensionSubtables.cpp +-ifeq ($(PLATFORM), linux) ++ifneq (,$(findstring $(PLATFORM), bsd linux)) + CXXFLAGS += $(CXXFLAGS_$(@F)) + CXXFLAGS_ExtensionSubtables.o = -fno-strict-aliasing + endif +@@ -178,7 +178,7 @@ # Libraries to link, and other C flags. # @@ -2055,8 +3010,8 @@ OTHER_INCLUDES += -I$(X11_PATH)/include OTHER_LDLIBS += -lawt $(LIBM) $(LIBCXX) ifeq ($(OS_VENDOR),Apple) ---- jdk/make/sun/jawt/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/jawt/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/sun/jawt/Makefile 2012-08-10 10:21:52.000000000 -0700 ++++ jdk/make/sun/jawt/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -94,8 +94,7 @@ # # Other extra flags needed for compiling. @@ -2084,8 +3039,8 @@ ifndef BUILD_HEADLESS_ONLY OTHER_LDLIBS = -L$(LIBDIR)/$(LIBARCH) -lawt -L$(LIBDIR)/$(LIBARCH)/xawt -lmawt else ---- jdk/make/sun/rmi/rmi/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/rmi/rmi/Makefile 2011-05-20 20:16:38.000000000 -0700 +--- jdk/make/sun/rmi/rmi/Makefile 2012-08-10 10:21:53.000000000 -0700 ++++ jdk/make/sun/rmi/rmi/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -97,6 +97,9 @@ BUILD_TARGETS += bin endif @@ -2096,8 +3051,8 @@ build: $(BUILD_TARGETS) ---- jdk/make/sun/splashscreen/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/splashscreen/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/sun/splashscreen/Makefile 2012-08-10 10:21:55.000000000 -0700 ++++ jdk/make/sun/splashscreen/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -83,15 +83,16 @@ -framework JavaNativeFoundation else ifneq ($(PLATFORM), windows) @@ -2123,8 +3078,8 @@ else # PLATFORM CFLAGS += -DWITH_WIN32 OTHER_LDLIBS += kernel32.lib user32.lib gdi32.lib delayimp.lib /DELAYLOAD:user32.dll ---- jdk/make/sun/xawt/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/sun/xawt/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/sun/xawt/Makefile 2012-08-10 10:21:55.000000000 -0700 ++++ jdk/make/sun/xawt/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -52,6 +52,9 @@ AUTO_JAVA_PRUNE = WrapperGenerator.java @@ -2177,8 +3132,8 @@ ifeq ($(PLATFORM), macosx) CPPFLAGS += -DX11_PATH=\"$(X11_PATH)\" -DPACKAGE_PATH=\"$(PACKAGE_PATH)\" endif ---- jdk/make/tools/freetypecheck/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/make/tools/freetypecheck/Makefile 2012-05-17 16:18:00.000000000 -0700 +--- jdk/make/tools/freetypecheck/Makefile 2012-08-10 10:22:31.000000000 -0700 ++++ jdk/make/tools/freetypecheck/Makefile 2012-08-19 12:39:47.000000000 -0700 @@ -52,8 +52,15 @@ else ifeq ($(PLATFORM), macosx) @@ -2198,7 +3153,7 @@ endif endif --- jdk/make/tools/sharing/classlist.bsd 1969-12-31 16:00:00.000000000 -0800 -+++ jdk/make/tools/sharing/classlist.bsd 2011-04-22 23:08:17.000000000 -0700 ++++ jdk/make/tools/sharing/classlist.bsd 2012-08-19 12:39:47.000000000 -0700 @@ -0,0 +1,2327 @@ +java/lang/Object +java/lang/String @@ -4527,8 +5482,1375 @@ +sun/applet/AppletPanel$6 +javax/swing/BufferStrategyPaintManager$1 +# f3ac8b467e7f8c49 ---- jdk/src/share/classes/java/util/TimeZone.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/java/util/TimeZone.java 2012-05-17 16:14:57.000000000 -0700 +--- jdk/src/macosx/classes/com/apple/laf/AquaPanelUI.java 2012-08-10 10:23:05.000000000 -0700 ++++ jdk/src/macosx/classes/com/apple/laf/AquaPanelUI.java 2012-08-19 12:39:48.000000000 -0700 +@@ -32,20 +32,10 @@ + import com.apple.laf.AquaUtils.RecyclableSingleton; + import com.apple.laf.AquaUtils.RecyclableSingletonFromDefaultConstructor; + +-import java.awt.Graphics; +- + public class AquaPanelUI extends BasicPanelUI { + static RecyclableSingleton<AquaPanelUI> instance = new RecyclableSingletonFromDefaultConstructor<AquaPanelUI>(AquaPanelUI.class); + + public static ComponentUI createUI(final JComponent c) { + return instance.get(); + } +- +- @Override +- public final void update(final Graphics g, final JComponent c) { +- if (c.isOpaque()) { +- AquaUtils.fillRect(g, c); +- } +- paint(g, c); +- } + } +--- jdk/src/macosx/classes/com/apple/laf/AquaRootPaneUI.java 2012-08-10 10:23:07.000000000 -0700 ++++ jdk/src/macosx/classes/com/apple/laf/AquaRootPaneUI.java 2012-08-19 12:39:48.000000000 -0700 +@@ -319,12 +319,4 @@ + updateComponentTreeUIActivation(element, active); + } + } +- +- @Override +- public final void update(final Graphics g, final JComponent c) { +- if (c.isOpaque()) { +- AquaUtils.fillRect(g, c); +- } +- paint(g, c); +- } + } +--- jdk/src/macosx/classes/com/apple/laf/AquaToolBarUI.java 2012-08-10 10:23:07.000000000 -0700 ++++ jdk/src/macosx/classes/com/apple/laf/AquaToolBarUI.java 2012-08-19 12:39:48.000000000 -0700 +@@ -73,7 +73,9 @@ + g.translate(x, y); + + if (c.isOpaque()) { +- AquaUtils.fillRect(g, c, c.getBackground(), 0, 0, w - 1, h - 1); ++ final Color background = c.getBackground(); ++ g.setColor(background); ++ g.fillRect(0, 0, w - 1, h - 1); + } + + final Color oldColor = g.getColor(); +@@ -135,12 +137,4 @@ + return true; + } + } +- +- @Override +- public final void update(final Graphics g, final JComponent c) { +- if (c.isOpaque()) { +- AquaUtils.fillRect(g, c); +- } +- paint(g, c); +- } + } +--- jdk/src/macosx/classes/com/apple/laf/AquaUtils.java 2012-08-10 10:23:08.000000000 -0700 ++++ jdk/src/macosx/classes/com/apple/laf/AquaUtils.java 2012-08-19 12:39:48.000000000 -0700 +@@ -28,19 +28,18 @@ + import java.awt.*; + import java.awt.image.*; + import java.lang.ref.SoftReference; ++import java.lang.ref.WeakReference; + import java.lang.reflect.Method; + import java.security.PrivilegedAction; + import java.util.*; + + import javax.swing.*; + import javax.swing.border.Border; +-import javax.swing.plaf.UIResource; + + import sun.awt.AppContext; + + import sun.lwawt.macosx.CImage; + import sun.lwawt.macosx.CImage.Creator; +-import sun.lwawt.macosx.CPlatformWindow; + import sun.swing.SwingUtilities2; + + import com.apple.laf.AquaImageFactory.SlicedImageControl; +@@ -390,51 +389,4 @@ + return false; + } + } +- +- protected static boolean isWindowTextured(final Component c) { +- if (!(c instanceof JComponent)) { +- return false; +- } +- final JRootPane pane = ((JComponent) c).getRootPane(); +- if (pane == null) { +- return false; +- } +- Object prop = pane.getClientProperty( +- CPlatformWindow.WINDOW_BRUSH_METAL_LOOK); +- if (prop != null) { +- return Boolean.parseBoolean(prop.toString()); +- } +- prop = pane.getClientProperty(CPlatformWindow.WINDOW_STYLE); +- return prop != null && "textured".equals(prop); +- } +- +- private static Color resetAlpha(final Color color) { +- return new Color(color.getRed(), color.getGreen(), color.getBlue(), 0); +- } +- +- protected static void fillRect(final Graphics g, final Component c) { +- fillRect(g, c, c.getBackground(), 0, 0, c.getWidth(), c.getHeight()); +- } +- +- protected static void fillRect(final Graphics g, final Component c, +- final Color color, final int x, final int y, +- final int w, final int h) { +- if (!(g instanceof Graphics2D)) { +- return; +- } +- final Graphics2D cg = (Graphics2D) g.create(); +- try { +- if (color instanceof UIResource && isWindowTextured(c) +- && color.equals(SystemColor.window)) { +- cg.setComposite(AlphaComposite.Src); +- cg.setColor(resetAlpha(color)); +- } else { +- cg.setColor(color); +- } +- cg.fillRect(x, y, w, h); +- } finally { +- cg.dispose(); +- } +- } + } +- +--- jdk/src/macosx/classes/sun/java2d/opengl/CGLLayer.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/java2d/opengl/CGLLayer.java 2012-08-19 12:39:48.000000000 -0700 +@@ -68,12 +68,11 @@ + } + + public boolean isOpaque() { +- return !peer.isTranslucent(); ++ return peer.isOpaque(); + } + + public int getTransparency() { +- return peer.isTranslucent() ? Transparency.TRANSLUCENT : +- Transparency.OPAQUE; ++ return (peer.isOpaque() ? Transparency.OPAQUE : Transparency.TRANSLUCENT); + } + + public Object getDestination() { +--- jdk/src/macosx/classes/sun/lwawt/LWComponentPeer.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWComponentPeer.java 2012-08-19 12:39:48.000000000 -0700 +@@ -424,7 +424,8 @@ + + @Override + public final Graphics getGraphics() { +- final Graphics g = getOnscreenGraphics(); ++ Graphics g = getWindowPeerOrSelf().isOpaque() ? getOnscreenGraphics() ++ : getOffscreenGraphics(); + if (g != null) { + synchronized (getPeerTreeLock()){ + applyConstrain(g); +@@ -442,7 +443,13 @@ + final LWWindowPeer wp = getWindowPeerOrSelf(); + return wp.getOnscreenGraphics(getForeground(), getBackground(), + getFont()); ++ } ++ ++ public final Graphics getOffscreenGraphics() { ++ final LWWindowPeer wp = getWindowPeerOrSelf(); + ++ return wp.getOffscreenGraphics(getForeground(), getBackground(), ++ getFont()); + } + + private void applyConstrain(final Graphics g) { +@@ -456,7 +463,7 @@ + } + + //TODO Move this method to SG2D? +- void SG2DConstraint(final SunGraphics2D sg2d, Region r) { ++ private void SG2DConstraint(final SunGraphics2D sg2d, Region r) { + sg2d.constrainX = sg2d.transX; + sg2d.constrainY = sg2d.transY; + +@@ -703,7 +710,7 @@ + // Obtain the metrics from the offscreen window where this peer is + // mostly drawn to. + // TODO: check for "use platform metrics" settings +- Graphics g = getWindowPeer().getGraphics(); ++ Graphics g = getWindowPeer().getOffscreenGraphics(); + try { + if (g != null) { + return g.getFontMetrics(f); +@@ -1004,33 +1011,14 @@ + @Override + public final void applyShape(final Region shape) { + synchronized (getStateLock()) { +- if (region == shape || (region != null && region.equals(shape))) { +- return; +- } +- } +- applyShapeImpl(shape); +- } +- +- void applyShapeImpl(final Region shape) { +- synchronized (getStateLock()) { +- if (shape != null) { +- region = Region.WHOLE_REGION.getIntersection(shape); +- } else { +- region = null; +- } ++ region = shape; + } + repaintParent(getBounds()); + } + + protected final Region getRegion() { + synchronized (getStateLock()) { +- return isShaped() ? region : Region.getInstance(getSize()); +- } +- } +- +- public boolean isShaped() { +- synchronized (getStateLock()) { +- return region != null; ++ return region == null ? Region.getInstance(getSize()) : region; + } + } + +@@ -1398,6 +1386,11 @@ + } + } + ++ // Just a helper method, thus final ++ protected final void flushOffscreenGraphics() { ++ flushOffscreenGraphics(getSize()); ++ } ++ + protected static final void flushOnscreenGraphics(){ + final OGLRenderQueue rq = OGLRenderQueue.getInstance(); + rq.lock(); +@@ -1408,6 +1401,36 @@ + } + } + ++ /* ++ * Flushes the given rectangle from the back buffer to the screen. ++ */ ++ protected void flushOffscreenGraphics(Rectangle r) { ++ flushOffscreenGraphics(r.x, r.y, r.width, r.height); ++ } ++ ++ private void flushOffscreenGraphics(int x, int y, int width, int height) { ++ Image bb = getWindowPeerOrSelf().getBackBuffer(); ++ if (bb != null) { ++ // g is a screen Graphics from the delegate ++ final Graphics g = getOnscreenGraphics(); ++ ++ if (g != null && g instanceof Graphics2D) { ++ try { ++ Graphics2D g2d = (Graphics2D)g; ++ Point p = localToWindow(new Point(0, 0)); ++ Composite composite = g2d.getComposite(); ++ g2d.setComposite(AlphaComposite.Src); ++ g.drawImage(bb, x, y, x + width, y + height, p.x + x, ++ p.y + y, p.x + x + width, p.y + y + height, ++ null); ++ g2d.setComposite(composite); ++ } finally { ++ g.dispose(); ++ } ++ } ++ } ++ } ++ + /** + * Used by ContainerPeer to skip all the paint events during layout. + * +--- jdk/src/macosx/classes/sun/lwawt/LWRepaintArea.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWRepaintArea.java 2012-08-19 12:39:48.000000000 -0700 +@@ -58,6 +58,9 @@ + + private static void flushBuffers(final LWComponentPeer peer) { + if (peer != null) { ++ if (!peer.getWindowPeerOrSelf().isOpaque()) { ++ peer.flushOffscreenGraphics(); ++ } + peer.flushOnscreenGraphics(); + } + } +--- jdk/src/macosx/classes/sun/lwawt/LWTextAreaPeer.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWTextAreaPeer.java 2012-08-19 12:39:48.000000000 -0700 +@@ -129,6 +129,16 @@ + } + + @Override ++ public void setText(final String l) { ++ // Please note that we do not want to post an event ++ // if TextArea.setText() replaces an empty text by an empty text, ++ // that is, if component's text remains unchanged. ++ if (!l.isEmpty() || getTextComponent().getDocument().getLength() != 0) { ++ super.setText(l); ++ } ++ } ++ ++ @Override + public void replaceRange(final String text, final int start, + final int end) { + synchronized (getDelegateLock()) { +--- jdk/src/macosx/classes/sun/lwawt/LWTextComponentPeer.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWTextComponentPeer.java 2012-08-19 12:39:48.000000000 -0700 +@@ -124,7 +124,7 @@ + } + + @Override +- public final void setText(final String l) { ++ public void setText(final String l) { + synchronized (getDelegateLock()) { + // JTextArea.setText() posts two different events (remove & insert). + // Since we make no differences between text events, +--- jdk/src/macosx/classes/sun/lwawt/LWToolkit.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWToolkit.java 2012-08-19 12:39:48.000000000 -0700 +@@ -522,6 +522,12 @@ + postEvent(targetToAppContext(event.getSource()), event); + } + ++ // use peer's back buffer to implement non-opaque windows. ++ @Override ++ public boolean needUpdateWindow() { ++ return true; ++ } ++ + @Override + public void grab(Window w) { + if (w.getPeer() != null) { +--- jdk/src/macosx/classes/sun/lwawt/LWWindowPeer.java 2012-08-10 10:23:11.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/LWWindowPeer.java 2012-08-19 12:39:48.000000000 -0700 +@@ -37,7 +37,6 @@ + import sun.java2d.*; + import sun.java2d.loops.Blit; + import sun.java2d.loops.CompositeType; +-import sun.java2d.pipe.Region; + import sun.util.logging.PlatformLogger; + + public class LWWindowPeer +@@ -110,10 +109,6 @@ + + private volatile boolean skipNextFocusChange; + +- private static final Color nonOpaqueBackground = new Color(0, 0, 0, 0); +- +- private volatile boolean textured; +- + /** + * Current modal blocker or null. + * +@@ -174,11 +169,6 @@ + setAlwaysOnTop(getTarget().isAlwaysOnTop()); + updateMinimumSize(); + +- final Shape shape = getTarget().getShape(); +- if (shape != null) { +- applyShape(Region.getInstance(shape, null)); +- } +- + final float opacity = getTarget().getOpacity(); + if (opacity < 1.0f) { + setOpacity(opacity); +@@ -188,7 +178,7 @@ + + updateInsets(platformWindow.getInsets()); + if (getSurfaceData() == null) { +- replaceSurfaceData(false); ++ replaceSurfaceData(); + } + } + +@@ -289,7 +279,7 @@ + // "buffer", that's why numBuffers - 1 + assert numBuffers > 1; + +- replaceSurfaceData(numBuffers - 1, caps, false); ++ replaceSurfaceData(numBuffers - 1, caps); + } catch (InvalidPipeException z) { + throw new AWTException(z.toString()); + } +@@ -451,44 +441,19 @@ + public final void setOpaque(final boolean isOpaque) { + if (this.isOpaque != isOpaque) { + this.isOpaque = isOpaque; +- updateOpaque(); ++ getPlatformWindow().setOpaque(isOpaque); ++ replaceSurfaceData(); ++ repaintPeer(); + } + } + +- private void updateOpaque() { +- getPlatformWindow().setOpaque(!isTranslucent()); +- replaceSurfaceData(false); +- repaintPeer(); ++ public final boolean isOpaque() { ++ return isOpaque; + } + + @Override + public void updateWindow() { +- } +- +- public final boolean isTextured() { +- return textured; +- } +- +- public final void setTextured(final boolean isTextured) { +- textured = isTextured; +- } +- +- public final boolean isTranslucent() { +- synchronized (getStateLock()) { +- /* +- * Textured window is a special case of translucent window. +- * The difference is only in nswindow background. So when we set +- * texture property our peer became fully translucent. It doesn't +- * fill background, create non opaque backbuffers and layer etc. +- */ +- return !isOpaque || isShaped() || isTextured(); +- } +- } +- +- @Override +- final void applyShapeImpl(final Region shape) { +- super.applyShapeImpl(shape); +- updateOpaque(); ++ flushOffscreenGraphics(); + } + + @Override +@@ -643,20 +608,7 @@ + getFont()); + if (g != null) { + try { +- if (g instanceof Graphics2D) { +- ((Graphics2D) g).setComposite(AlphaComposite.Src); +- } +- if (isTranslucent()) { +- g.setColor(nonOpaqueBackground); +- g.fillRect(0, 0, w, h); +- } +- if (!isTextured()) { +- if (g instanceof SunGraphics2D) { +- SG2DConstraint((SunGraphics2D) g, getRegion()); +- } +- g.setColor(getBackground()); +- g.fillRect(0, 0, w, h); +- } ++ g.clearRect(0, 0, w, h); + } finally { + g.dispose(); + } +@@ -963,6 +915,35 @@ + }); + } + ++ /** ++ * This method returns a back buffer Graphics to render all the ++ * peers to. After the peer is painted, the back buffer contents ++ * should be flushed to the screen. All the target painting ++ * (Component.paint() method) should be done directly to the screen. ++ */ ++ protected final Graphics getOffscreenGraphics(Color fg, Color bg, Font f) { ++ final Image bb = getBackBuffer(); ++ if (bb == null) { ++ return null; ++ } ++ if (fg == null) { ++ fg = SystemColor.windowText; ++ } ++ if (bg == null) { ++ bg = SystemColor.window; ++ } ++ if (f == null) { ++ f = DEFAULT_FONT; ++ } ++ final Graphics2D g = (Graphics2D) bb.getGraphics(); ++ if (g != null) { ++ g.setColor(fg); ++ g.setBackground(bg); ++ g.setFont(f); ++ } ++ return g; ++ } ++ + /* + * May be called by delegate to provide SD to Java2D code. + */ +@@ -973,16 +954,11 @@ + } + + private void replaceSurfaceData() { +- replaceSurfaceData(true); +- } +- +- private void replaceSurfaceData(boolean blit) { +- replaceSurfaceData(backBufferCount, backBufferCaps, blit); ++ replaceSurfaceData(backBufferCount, backBufferCaps); + } + + private void replaceSurfaceData(int newBackBufferCount, +- BufferCapabilities newBackBufferCaps, +- boolean blit) { ++ BufferCapabilities newBackBufferCaps) { + synchronized (surfaceDataLock) { + final SurfaceData oldData = getSurfaceData(); + surfaceData = platformWindow.replaceSurfaceData(); +@@ -995,10 +971,7 @@ + if (getSurfaceData() != null && oldData != getSurfaceData()) { + clearBackground(size.width, size.height); + } +- +- if (blit) { +- blitSurfaceData(oldData, getSurfaceData()); +- } ++ blitSurfaceData(oldData, getSurfaceData()); + + if (oldData != null && oldData != getSurfaceData()) { + // TODO: drop oldData for D3D/WGL pipelines +@@ -1013,18 +986,11 @@ + Graphics g = backBuffer.getGraphics(); + try { + Rectangle r = getBounds(); ++ g.setColor(getBackground()); + if (g instanceof Graphics2D) { + ((Graphics2D) g).setComposite(AlphaComposite.Src); + } +- g.setColor(nonOpaqueBackground); + g.fillRect(0, 0, r.width, r.height); +- if (g instanceof SunGraphics2D) { +- SG2DConstraint((SunGraphics2D) g, getRegion()); +- } +- if (!isTextured()) { +- g.setColor(getBackground()); +- g.fillRect(0, 0, r.width, r.height); +- } + if (oldBB != null) { + // Draw the old back buffer to the new one + g.drawImage(oldBB, 0, 0, null); +@@ -1048,7 +1014,7 @@ + CompositeType.Src, + dst.getSurfaceType()); + if (blit != null) { +- blit.Blit(src, dst, AlphaComposite.Src, ++ blit.Blit(src, dst, ((Graphics2D) getGraphics()).getComposite(), + getRegion(), 0, 0, 0, 0, size.width, size.height); + } + } +--- jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformEmbeddedFrame.java 2012-08-10 10:23:13.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformEmbeddedFrame.java 2012-08-19 12:39:48.000000000 -0700 +@@ -117,7 +117,7 @@ + Rectangle r = peer.getBounds(); + Image im = null; + if (!r.isEmpty()) { +- int transparency = peer.isTranslucent() ? Transparency.TRANSLUCENT : Transparency.OPAQUE; ++ int transparency = (peer.isOpaque() ? Transparency.OPAQUE : Transparency.TRANSLUCENT); + im = peer.getGraphicsConfiguration().createCompatibleImage(r.width, r.height, transparency); + } + return im; +--- jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformView.java 2012-08-10 10:23:13.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformView.java 2012-08-19 12:39:48.000000000 -0700 +@@ -64,7 +64,7 @@ + } + + public boolean isOpaque() { +- return !peer.isTranslucent(); ++ return peer.isOpaque(); + } + + /* +--- jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java 2012-08-10 10:23:13.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java 2012-08-19 12:39:48.000000000 -0700 +@@ -299,7 +299,7 @@ + + // If the target is a dialog, popup or tooltip we want it to ignore the brushed metal look. + if (isPopup) { +- styleBits = SET(styleBits, TEXTURED, false); ++ styleBits = SET(styleBits, TEXTURED, true); + // Popups in applets don't activate applet's process + styleBits = SET(styleBits, NONACTIVATING, true); + } +@@ -373,8 +373,6 @@ + } + } + +- peer.setTextured(IS(TEXTURED, styleBits)); +- + return styleBits; + } + +@@ -742,19 +740,10 @@ + @Override + public void setOpaque(boolean isOpaque) { + CWrapper.NSWindow.setOpaque(getNSWindowPtr(), isOpaque); +- if (!isOpaque && !peer.isTextured()) { ++ if (!isOpaque) { + long clearColor = CWrapper.NSColor.clearColor(); + CWrapper.NSWindow.setBackgroundColor(getNSWindowPtr(), clearColor); + } +- +- //This is a temporary workaround. Looks like after 7124236 will be fixed +- //the correct place for invalidateShadow() is CGLayer.drawInCGLContext. +- SwingUtilities.invokeLater(new Runnable() { +- @Override +- public void run() { +- invalidateShadow(); +- } +- }); + } + + @Override +@@ -824,10 +813,6 @@ + } + + +- public final void invalidateShadow(){ +- nativeRevalidateNSWindowShadow(getNSWindowPtr()); +- } +- + // ---------------------------------------------------------------------- + // UTILITY METHODS + // ---------------------------------------------------------------------- +--- jdk/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java 2012-08-10 10:23:14.000000000 -0700 ++++ jdk/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java 2012-08-19 12:39:48.000000000 -0700 +@@ -759,11 +759,6 @@ + } + + @Override +- public boolean isWindowShapingSupported() { +- return true; +- } +- +- @Override + public boolean isWindowTranslucencySupported() { + return true; + } +@@ -773,10 +768,6 @@ + return true; + } + +- public boolean isSwingBackbufferTranslucencySupported() { +- return true; +- } +- + @Override + public boolean enableInputMethodsForTextComponent() { + return true; +--- jdk/src/macosx/native/sun/awt/AWTWindow.m 2012-08-10 10:23:21.000000000 -0700 ++++ jdk/src/macosx/native/sun/awt/AWTWindow.m 2012-08-19 12:39:48.000000000 -0700 +@@ -1017,17 +1017,14 @@ + (JNIEnv *env, jclass clazz, jlong windowPtr) + { + JNF_COCOA_ENTER(env); ++AWT_ASSERT_NOT_APPKIT_THREAD; + + NSWindow *nsWindow = OBJC(windowPtr); +- if ([NSThread isMainThread]) { ++ [JNFRunLoop performOnMainThreadWaiting:NO withBlock:^(){ ++ AWT_ASSERT_APPKIT_THREAD; ++ + [nsWindow invalidateShadow]; +- } else { +- [JNFRunLoop performOnMainThreadWaiting:NO withBlock:^(){ +- AWT_ASSERT_APPKIT_THREAD; +- +- [nsWindow invalidateShadow]; +- }]; +- } ++ }]; + + JNF_COCOA_EXIT(env); + } +--- jdk/src/share/classes/com/sun/beans/TypeResolver.java 2012-08-10 10:23:31.000000000 -0700 ++++ jdk/src/share/classes/com/sun/beans/TypeResolver.java 2012-08-19 12:39:49.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2003, 2006, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -45,9 +45,6 @@ + * @author Sergey Malenkov + */ + public final class TypeResolver { +- +- private static final WeakCache<Type, Map<Type, Type>> CACHE = new WeakCache<>(); +- + /** + * Replaces the given {@code type} in an inherited method + * with the actual type it has in the given {@code inClass}. +@@ -152,55 +149,12 @@ + * @param formal the type where occurrences of the variables + * in {@code actual} will be replaced by the corresponding bound values + * @return a resolved type ++ * ++ * @see #TypeResolver(Type) ++ * @see #resolve(Type) + */ + public static Type resolve(Type actual, Type formal) { +- if (formal instanceof Class) { +- return formal; +- } +- if (formal instanceof GenericArrayType) { +- Type comp = ((GenericArrayType) formal).getGenericComponentType(); +- comp = resolve(actual, comp); +- return (comp instanceof Class) +- ? Array.newInstance((Class<?>) comp, 0).getClass() +- : GenericArrayTypeImpl.make(comp); +- } +- if (formal instanceof ParameterizedType) { +- ParameterizedType fpt = (ParameterizedType) formal; +- Type[] actuals = resolve(actual, fpt.getActualTypeArguments()); +- return ParameterizedTypeImpl.make( +- (Class<?>) fpt.getRawType(), actuals, fpt.getOwnerType()); +- } +- if (formal instanceof WildcardType) { +- WildcardType fwt = (WildcardType) formal; +- Type[] upper = resolve(actual, fwt.getUpperBounds()); +- Type[] lower = resolve(actual, fwt.getLowerBounds()); +- return new WildcardTypeImpl(upper, lower); +- } +- if (formal instanceof TypeVariable) { +- Map<Type, Type> map; +- synchronized (CACHE) { +- map = CACHE.get(actual); +- if (map == null) { +- map = new HashMap<>(); +- prepare(map, actual); +- CACHE.put(actual, map); +- } +- } +- Type result = map.get(formal); +- if (result == null || result.equals(formal)) { +- return formal; +- } +- result = fixGenericArray(result); +- // A variable can be bound to another variable that is itself bound +- // to something. For example, given: +- // class Super<T> {...} +- // class Mid<X> extends Super<T> {...} +- // class Sub extends Mid<String> +- // the variable T is bound to X, which is in turn bound to String. +- // So if we have to resolve T, we need the tail recursion here. +- return resolve(actual, result); +- } +- throw new IllegalArgumentException("Bad Type kind: " + formal.getClass()); ++ return getTypeResolver(actual).resolve(formal); + } + + /** +@@ -210,14 +164,12 @@ + * @param actual the type that supplies bindings for type variables + * @param formals the array of types to resolve + * @return an array of resolved types ++ * ++ * @see #TypeResolver(Type) ++ * @see #resolve(Type[]) + */ + public static Type[] resolve(Type actual, Type[] formals) { +- int length = formals.length; +- Type[] actuals = new Type[length]; +- for (int i = 0; i < length; i++) { +- actuals[i] = resolve(actual, formals[i]); +- } +- return actuals; ++ return getTypeResolver(actual).resolve(formals); + } + + /** +@@ -276,6 +228,32 @@ + return classes; + } + ++ public static TypeResolver getTypeResolver(Type type) { ++ synchronized (CACHE) { ++ TypeResolver resolver = CACHE.get(type); ++ if (resolver == null) { ++ resolver = new TypeResolver(type); ++ CACHE.put(type, resolver); ++ } ++ return resolver; ++ } ++ } ++ ++ private static final WeakCache<Type, TypeResolver> CACHE = new WeakCache<>(); ++ ++ private final Map<TypeVariable<?>, Type> map = new HashMap<>(); ++ ++ /** ++ * Constructs the type resolver for the given actual type. ++ * ++ * @param actual the type that supplies bindings for type variables ++ * ++ * @see #prepare(Type) ++ */ ++ private TypeResolver(Type actual) { ++ prepare(actual); ++ } ++ + /** + * Fills the map from type parameters + * to types as seen by the given {@code type}. +@@ -287,10 +265,9 @@ + * to a {@link ParameterizedType ParameterizedType} with no parameters, + * or it represents the erasure of a {@link ParameterizedType ParameterizedType}. + * +- * @param map the mappings of all type variables + * @param type the next type in the hierarchy + */ +- private static void prepare(Map<Type, Type> map, Type type) { ++ private void prepare(Type type) { + Class<?> raw = (Class<?>)((type instanceof Class<?>) + ? type + : ((ParameterizedType)type).getRawType()); +@@ -303,25 +280,91 @@ + + assert formals.length == actuals.length; + for (int i = 0; i < formals.length; i++) { +- map.put(formals[i], actuals[i]); ++ this.map.put(formals[i], actuals[i]); + } + Type gSuperclass = raw.getGenericSuperclass(); + if (gSuperclass != null) { +- prepare(map, gSuperclass); ++ prepare(gSuperclass); + } + for (Type gInterface : raw.getGenericInterfaces()) { +- prepare(map, gInterface); ++ prepare(gInterface); + } + // If type is the raw version of a parameterized class, we type-erase + // all of its type variables, including inherited ones. + if (type instanceof Class<?> && formals.length > 0) { +- for (Map.Entry<Type, Type> entry : map.entrySet()) { ++ for (Map.Entry<TypeVariable<?>, Type> entry : this.map.entrySet()) { + entry.setValue(erase(entry.getValue())); + } + } + } + + /** ++ * Replaces the given {@code formal} type ++ * with the type it stand for in this type resolver. ++ * ++ * @param formal the array of types to resolve ++ * @return a resolved type ++ */ ++ private Type resolve(Type formal) { ++ if (formal instanceof Class) { ++ return formal; ++ } ++ if (formal instanceof GenericArrayType) { ++ Type comp = ((GenericArrayType)formal).getGenericComponentType(); ++ comp = resolve(comp); ++ return (comp instanceof Class) ++ ? Array.newInstance((Class<?>)comp, 0).getClass() ++ : GenericArrayTypeImpl.make(comp); ++ } ++ if (formal instanceof ParameterizedType) { ++ ParameterizedType fpt = (ParameterizedType)formal; ++ Type[] actuals = resolve(fpt.getActualTypeArguments()); ++ return ParameterizedTypeImpl.make( ++ (Class<?>)fpt.getRawType(), actuals, fpt.getOwnerType()); ++ } ++ if (formal instanceof WildcardType) { ++ WildcardType fwt = (WildcardType)formal; ++ Type[] upper = resolve(fwt.getUpperBounds()); ++ Type[] lower = resolve(fwt.getLowerBounds()); ++ return new WildcardTypeImpl(upper, lower); ++ } ++ if (!(formal instanceof TypeVariable)) { ++ throw new IllegalArgumentException("Bad Type kind: " + formal.getClass()); ++ } ++ Type actual = this.map.get((TypeVariable) formal); ++ if (actual == null || actual.equals(formal)) { ++ return formal; ++ } ++ actual = fixGenericArray(actual); ++ return resolve(actual); ++ // A variable can be bound to another variable that is itself bound ++ // to something. For example, given: ++ // class Super<T> {...} ++ // class Mid<X> extends Super<T> {...} ++ // class Sub extends Mid<String> ++ // the variable T is bound to X, which is in turn bound to String. ++ // So if we have to resolve T, we need the tail recursion here. ++ } ++ ++ /** ++ * Replaces all formal types in the given array ++ * with the types they stand for in this type resolver. ++ * ++ * @param formals the array of types to resolve ++ * @return an array of resolved types ++ * ++ * @see #resolve(Type) ++ */ ++ private Type[] resolve(Type[] formals) { ++ int length = formals.length; ++ Type[] actuals = new Type[length]; ++ for (int i = 0; i < length; i++) { ++ actuals[i] = resolve(formals[i]); ++ } ++ return actuals; ++ } ++ ++ /** + * Replaces a {@link GenericArrayType GenericArrayType} + * with plain array class where it is possible. + * Bug <a href="http://bugs.sun.com/view_bug.do?bug_id=5041784">5041784</a> +--- jdk/src/share/classes/com/sun/beans/finder/MethodFinder.java 2012-08-10 10:23:33.000000000 -0700 ++++ jdk/src/share/classes/com/sun/beans/finder/MethodFinder.java 2012-08-19 12:39:49.000000000 -0700 +@@ -164,10 +164,8 @@ + return findAccessibleMethod(m); + } + Type[] gpts = m.getGenericParameterTypes(); +- if (params.length == gpts.length) { +- if (Arrays.equals(params, TypeResolver.erase(TypeResolver.resolve(pt, gpts)))) { +- return findAccessibleMethod(m); +- } ++ if (Arrays.equals(params, TypeResolver.erase(TypeResolver.resolve(pt, gpts)))) { ++ return findAccessibleMethod(m); + } + } + } +--- jdk/src/share/classes/com/sun/jndi/ldap/Connection.java 2012-08-10 10:24:27.000000000 -0700 ++++ jdk/src/share/classes/com/sun/jndi/ldap/Connection.java 2012-08-19 12:39:50.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -685,11 +685,9 @@ + ldr = ldr.next; + } + } ++ parent.processConnectionClosure(); + } + } +- if (nparent) { +- parent.processConnectionClosure(); +- } + } + + +--- jdk/src/share/classes/com/sun/jndi/ldap/LdapClient.java 2012-08-10 10:24:27.000000000 -0700 ++++ jdk/src/share/classes/com/sun/jndi/ldap/LdapClient.java 2012-08-19 12:39:50.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -487,16 +487,14 @@ + */ + void processConnectionClosure() { + // Notify listeners +- synchronized (unsolicited) { +- if (unsolicited.size() > 0) { +- String msg; +- if (conn != null) { +- msg = conn.host + ":" + conn.port + " connection closed"; +- } else { +- msg = "Connection closed"; +- } +- notifyUnsolicited(new CommunicationException(msg)); ++ if (unsolicited.size() > 0) { ++ String msg; ++ if (conn != null) { ++ msg = conn.host + ":" + conn.port + " connection closed"; ++ } else { ++ msg = "Connection closed"; + } ++ notifyUnsolicited(new CommunicationException(msg)); + } + + // Remove from pool +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_de.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_de.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=FileChooser-Hilfe + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=Ausgew\u00E4hltes Verzeichnis \u00F6ffnen + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Vorschau + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_es.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_es.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=Ayuda del Selector de Archivos + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=Abrir directorio seleccionado + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Vista Previa + ColorChooser.ok.textAndMnemonic=Aceptar +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_fr.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_fr.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=Aide du s\u00E9lecteur de fichiers + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=Ouvre le r\u00E9pertoire s\u00E9lectionn\u00E9 + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Aper\u00E7u + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_it.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_it.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=Guida FileChooser + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=Apre la directory selezionata + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Anteprima + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_ja.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_ja.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=FileChooser\u306E\u30D8\u30EB\u30D7\u3067\u3059 + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=\u9078\u629E\u3057\u305F\u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u3092\u958B\u304D\u307E\u3059 + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=\u30D7\u30EC\u30D3\u30E5\u30FC + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_ko.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_ko.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=FileChooser \uB3C4\uC6C0\uB9D0 + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=\uC120\uD0DD\uB41C \uB514\uB809\uD1A0\uB9AC \uC5F4\uAE30 + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=\uBBF8\uB9AC\uBCF4\uAE30 + ColorChooser.ok.textAndMnemonic=\uD655\uC778 +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_pt_BR.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_pt_BR.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=Ajuda do FileChooser + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=Abrir diret\u00F3rio selecionado + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Visualizar + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_sv.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_sv.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=Hj\u00E4lp - Filv\u00E4ljare + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=\u00D6ppna vald katalog + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=Granska + ColorChooser.ok.textAndMnemonic=OK +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_zh_CN.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_zh_CN.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=FileChooser \u5E2E\u52A9 + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=\u6253\u5F00\u9009\u62E9\u7684\u76EE\u5F55 + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=\u9884\u89C8 + ColorChooser.ok.textAndMnemonic=\u786E\u5B9A +--- jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_zh_TW.properties 2012-08-10 10:25:42.000000000 -0700 ++++ jdk/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic_zh_TW.properties 2012-08-19 12:39:50.000000000 -0700 +@@ -70,9 +70,6 @@ + FileChooser.helpButtonToolTip.textAndMnemonic=\u300C\u6A94\u6848\u9078\u64C7\u5668\u300D\u8AAA\u660E + FileChooser.directoryOpenButtonToolTip.textAndMnemonic=\u958B\u555F\u9078\u53D6\u7684\u76EE\u9304 + +-FileChooser.filesListAccessibleName=Files List +-FileChooser.filesDetailsAccessibleName=Files Details +- + ############ COLOR CHOOSER STRINGS ############# + ColorChooser.preview.textAndMnemonic=\u9810\u89BD + ColorChooser.ok.textAndMnemonic=\u78BA\u5B9A +--- jdk/src/share/classes/java/awt/TextComponent.java 2012-08-10 10:25:57.000000000 -0700 ++++ jdk/src/share/classes/java/awt/TextComponent.java 2012-08-19 12:39:51.000000000 -0700 +@@ -233,14 +233,9 @@ + * @see java.awt.TextComponent#getText + */ + public synchronized void setText(String t) { +- boolean skipTextEvent = (text == null || text.isEmpty()) +- && (t == null || t.isEmpty()); + text = (t != null) ? t : ""; + TextComponentPeer peer = (TextComponentPeer)this.peer; +- // Please note that we do not want to post an event +- // if TextArea.setText() or TextField.setText() replaces an empty text +- // by an empty text, that is, if component's text remains unchanged. +- if (peer != null && !skipTextEvent) { ++ if (peer != null) { + peer.setText(text); + } + } +--- jdk/src/share/classes/java/beans/IndexedPropertyDescriptor.java 2012-08-10 10:26:08.000000000 -0700 ++++ jdk/src/share/classes/java/beans/IndexedPropertyDescriptor.java 2012-08-19 12:39:51.000000000 -0700 +@@ -181,21 +181,20 @@ + // the Indexed readMethod was explicitly set to null. + return null; + } +- String nextMethodName = Introspector.GET_PREFIX + getBaseName(); + if (indexedReadMethodName == null) { + Class type = getIndexedPropertyType0(); + if (type == boolean.class || type == null) { + indexedReadMethodName = Introspector.IS_PREFIX + getBaseName(); + } else { +- indexedReadMethodName = nextMethodName; ++ indexedReadMethodName = Introspector.GET_PREFIX + getBaseName(); + } + } + + Class[] args = { int.class }; + indexedReadMethod = Introspector.findMethod(cls, indexedReadMethodName, 1, args); +- if ((indexedReadMethod == null) && !indexedReadMethodName.equals(nextMethodName)) { ++ if (indexedReadMethod == null) { + // no "is" method, so look for a "get" method. +- indexedReadMethodName = nextMethodName; ++ indexedReadMethodName = Introspector.GET_PREFIX + getBaseName(); + indexedReadMethod = Introspector.findMethod(cls, indexedReadMethodName, 1, args); + } + setIndexedReadMethod0(indexedReadMethod); +--- jdk/src/share/classes/java/beans/Introspector.java 2012-08-10 10:26:08.000000000 -0700 ++++ jdk/src/share/classes/java/beans/Introspector.java 2012-08-19 12:39:51.000000000 -0700 +@@ -25,7 +25,6 @@ + + package java.beans; + +-import com.sun.beans.TypeResolver; + import com.sun.beans.WeakCache; + import com.sun.beans.finder.ClassFinder; + +@@ -35,7 +34,6 @@ + import java.lang.ref.SoftReference; + import java.lang.reflect.Method; + import java.lang.reflect.Modifier; +-import java.lang.reflect.Type; + + import java.util.Map; + import java.util.ArrayList; +@@ -953,61 +951,44 @@ + continue; + } + +- if (name.startsWith(ADD_PREFIX)) { +- Class<?> returnType = method.getReturnType(); +- if (returnType == void.class) { +- Type[] parameterTypes = method.getGenericParameterTypes(); +- if (parameterTypes.length == 1) { +- Class<?> type = TypeResolver.erase(TypeResolver.resolveInClass(beanClass, parameterTypes[0])); +- if (Introspector.isSubclass(type, eventListenerType)) { +- String listenerName = name.substring(3); +- if (listenerName.length() > 0 && +- type.getName().endsWith(listenerName)) { +- if (adds == null) { +- adds = new HashMap(); +- } +- adds.put(listenerName, method); +- } +- } ++ Class argTypes[] = FeatureDescriptor.getParameterTypes(beanClass, method); ++ Class resultType = FeatureDescriptor.getReturnType(beanClass, method); ++ ++ if (name.startsWith(ADD_PREFIX) && argTypes.length == 1 && ++ resultType == Void.TYPE && ++ Introspector.isSubclass(argTypes[0], eventListenerType)) { ++ String listenerName = name.substring(3); ++ if (listenerName.length() > 0 && ++ argTypes[0].getName().endsWith(listenerName)) { ++ if (adds == null) { ++ adds = new HashMap(); + } ++ adds.put(listenerName, method); + } + } +- else if (name.startsWith(REMOVE_PREFIX)) { +- Class<?> returnType = method.getReturnType(); +- if (returnType == void.class) { +- Type[] parameterTypes = method.getGenericParameterTypes(); +- if (parameterTypes.length == 1) { +- Class<?> type = TypeResolver.erase(TypeResolver.resolveInClass(beanClass, parameterTypes[0])); +- if (Introspector.isSubclass(type, eventListenerType)) { +- String listenerName = name.substring(6); +- if (listenerName.length() > 0 && +- type.getName().endsWith(listenerName)) { +- if (removes == null) { +- removes = new HashMap(); +- } +- removes.put(listenerName, method); +- } +- } ++ else if (name.startsWith(REMOVE_PREFIX) && argTypes.length == 1 && ++ resultType == Void.TYPE && ++ Introspector.isSubclass(argTypes[0], eventListenerType)) { ++ String listenerName = name.substring(6); ++ if (listenerName.length() > 0 && ++ argTypes[0].getName().endsWith(listenerName)) { ++ if (removes == null) { ++ removes = new HashMap(); + } ++ removes.put(listenerName, method); + } + } +- else if (name.startsWith(GET_PREFIX)) { +- Class<?>[] parameterTypes = method.getParameterTypes(); +- if (parameterTypes.length == 0) { +- Class<?> returnType = FeatureDescriptor.getReturnType(beanClass, method); +- if (returnType.isArray()) { +- Class<?> type = returnType.getComponentType(); +- if (Introspector.isSubclass(type, eventListenerType)) { +- String listenerName = name.substring(3, name.length() - 1); +- if (listenerName.length() > 0 && +- type.getName().endsWith(listenerName)) { +- if (gets == null) { +- gets = new HashMap(); +- } +- gets.put(listenerName, method); +- } +- } ++ else if (name.startsWith(GET_PREFIX) && argTypes.length == 0 && ++ resultType.isArray() && ++ Introspector.isSubclass(resultType.getComponentType(), ++ eventListenerType)) { ++ String listenerName = name.substring(3, name.length() - 1); ++ if (listenerName.length() > 0 && ++ resultType.getComponentType().getName().endsWith(listenerName)) { ++ if (gets == null) { ++ gets = new HashMap(); + } ++ gets.put(listenerName, method); + } + } + } +@@ -1259,11 +1240,11 @@ + private boolean isEventHandler(Method m) { + // We assume that a method is an event handler if it has a single + // argument, whose type inherit from java.util.Event. +- Type argTypes[] = m.getGenericParameterTypes(); ++ Class argTypes[] = FeatureDescriptor.getParameterTypes(beanClass, m); + if (argTypes.length != 1) { + return false; + } +- return isSubclass(TypeResolver.erase(TypeResolver.resolveInClass(beanClass, argTypes[0])), EventObject.class); ++ return isSubclass(argTypes[0], EventObject.class); + } + + /* +@@ -1315,25 +1296,24 @@ + } + + // make sure method signature matches. +- if (method.getName().equals(methodName)) { +- Type[] params = method.getGenericParameterTypes(); +- if (params.length == argCount) { +- if (args != null) { +- boolean different = false; +- if (argCount > 0) { +- for (int j = 0; j < argCount; j++) { +- if (TypeResolver.erase(TypeResolver.resolveInClass(start, params[j])) != args[j]) { +- different = true; +- continue; +- } +- } +- if (different) { ++ Class params[] = FeatureDescriptor.getParameterTypes(start, method); ++ if (method.getName().equals(methodName) && ++ params.length == argCount) { ++ if (args != null) { ++ boolean different = false; ++ if (argCount > 0) { ++ for (int j = 0; j < argCount; j++) { ++ if (params[j] != args[j]) { ++ different = true; + continue; + } + } ++ if (different) { ++ continue; ++ } + } +- return method; + } ++ return method; + } + } + } +--- jdk/src/share/classes/java/beans/PropertyDescriptor.java 2012-08-10 10:26:08.000000000 -0700 ++++ jdk/src/share/classes/java/beans/PropertyDescriptor.java 2012-08-19 12:39:51.000000000 -0700 +@@ -210,13 +210,12 @@ + // The read method was explicitly set to null. + return null; + } +- String nextMethodName = Introspector.GET_PREFIX + getBaseName(); + if (readMethodName == null) { + Class type = getPropertyType0(); + if (type == boolean.class || type == null) { + readMethodName = Introspector.IS_PREFIX + getBaseName(); + } else { +- readMethodName = nextMethodName; ++ readMethodName = Introspector.GET_PREFIX + getBaseName(); + } + } + +@@ -226,8 +225,8 @@ + // methods. If an "is" method exists, this is the official + // reader method so look for this one first. + readMethod = Introspector.findMethod(cls, readMethodName, 0); +- if ((readMethod == null) && !readMethodName.equals(nextMethodName)) { +- readMethodName = nextMethodName; ++ if (readMethod == null) { ++ readMethodName = Introspector.GET_PREFIX + getBaseName(); + readMethod = Introspector.findMethod(cls, readMethodName, 0); + } + try { +--- jdk/src/share/classes/java/net/InMemoryCookieStore.java 2012-08-10 10:27:01.000000000 -0700 ++++ jdk/src/share/classes/java/net/InMemoryCookieStore.java 2012-08-19 12:39:52.000000000 -0700 +@@ -91,10 +91,8 @@ + if (cookie.getDomain() != null) { + addIndex(domainIndex, cookie.getDomain(), cookie); + } +- if (uri != null) { +- // add it to uri index, too +- addIndex(uriIndex, getEffectiveURI(uri), cookie); +- } ++ // add it to uri index, too ++ addIndex(uriIndex, getEffectiveURI(uri), cookie); + } + } finally { + lock.unlock(); +--- jdk/src/share/classes/java/util/TimeZone.java 2012-08-10 10:27:19.000000000 -0700 ++++ jdk/src/share/classes/java/util/TimeZone.java 2012-08-19 12:39:52.000000000 -0700 @@ -890,15 +890,13 @@ } int gmtOffset = (hours * 60 + num) * 60 * 1000; @@ -4546,8 +6868,504 @@ } return zi; } ---- jdk/src/share/classes/sun/awt/FontConfiguration.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/awt/FontConfiguration.java 2012-02-26 15:38:42.000000000 -0800 +--- jdk/src/share/classes/java/util/concurrent/PriorityBlockingQueue.java 2012-08-10 10:27:20.000000000 -0700 ++++ jdk/src/share/classes/java/util/concurrent/PriorityBlockingQueue.java 2012-08-19 12:39:53.000000000 -0700 +@@ -35,8 +35,7 @@ + + package java.util.concurrent; + +-import java.util.concurrent.locks.Condition; +-import java.util.concurrent.locks.ReentrantLock; ++import java.util.concurrent.locks.*; + import java.util.*; + + /** +@@ -111,7 +110,7 @@ + * java.util.PriorityQueue operations within a lock, as was done + * in a previous version of this class. To maintain + * interoperability, a plain PriorityQueue is still used during +- * serialization, which maintains compatibility at the expense of ++ * serialization, which maintains compatibility at the espense of + * transiently doubling overhead. + */ + +@@ -308,13 +307,14 @@ + /** + * Mechanics for poll(). Call only while holding lock. + */ +- private E dequeue() { ++ private E extract() { ++ E result; + int n = size - 1; + if (n < 0) +- return null; ++ result = null; + else { + Object[] array = queue; +- E result = (E) array[0]; ++ result = (E) array[0]; + E x = (E) array[n]; + array[n] = null; + Comparator<? super E> cmp = comparator; +@@ -323,8 +323,8 @@ + else + siftDownUsingComparator(0, x, array, n, cmp); + size = n; +- return result; + } ++ return result; + } + + /** +@@ -381,43 +381,39 @@ + */ + private static <T> void siftDownComparable(int k, T x, Object[] array, + int n) { +- if (n > 0) { +- Comparable<? super T> key = (Comparable<? super T>)x; +- int half = n >>> 1; // loop while a non-leaf +- while (k < half) { +- int child = (k << 1) + 1; // assume left child is least +- Object c = array[child]; +- int right = child + 1; +- if (right < n && +- ((Comparable<? super T>) c).compareTo((T) array[right]) > 0) +- c = array[child = right]; +- if (key.compareTo((T) c) <= 0) +- break; +- array[k] = c; +- k = child; +- } +- array[k] = key; ++ Comparable<? super T> key = (Comparable<? super T>)x; ++ int half = n >>> 1; // loop while a non-leaf ++ while (k < half) { ++ int child = (k << 1) + 1; // assume left child is least ++ Object c = array[child]; ++ int right = child + 1; ++ if (right < n && ++ ((Comparable<? super T>) c).compareTo((T) array[right]) > 0) ++ c = array[child = right]; ++ if (key.compareTo((T) c) <= 0) ++ break; ++ array[k] = c; ++ k = child; + } ++ array[k] = key; + } + + private static <T> void siftDownUsingComparator(int k, T x, Object[] array, + int n, + Comparator<? super T> cmp) { +- if (n > 0) { +- int half = n >>> 1; +- while (k < half) { +- int child = (k << 1) + 1; +- Object c = array[child]; +- int right = child + 1; +- if (right < n && cmp.compare((T) c, (T) array[right]) > 0) +- c = array[child = right]; +- if (cmp.compare(x, (T) c) <= 0) +- break; +- array[k] = c; +- k = child; +- } +- array[k] = x; ++ int half = n >>> 1; ++ while (k < half) { ++ int child = (k << 1) + 1; ++ Object c = array[child]; ++ int right = child + 1; ++ if (right < n && cmp.compare((T) c, (T) array[right]) > 0) ++ c = array[child = right]; ++ if (cmp.compare(x, (T) c) <= 0) ++ break; ++ array[k] = c; ++ k = child; + } ++ array[k] = x; + } + + /** +@@ -523,11 +519,13 @@ + public E poll() { + final ReentrantLock lock = this.lock; + lock.lock(); ++ E result; + try { +- return dequeue(); ++ result = extract(); + } finally { + lock.unlock(); + } ++ return result; + } + + public E take() throws InterruptedException { +@@ -535,7 +533,7 @@ + lock.lockInterruptibly(); + E result; + try { +- while ( (result = dequeue()) == null) ++ while ( (result = extract()) == null) + notEmpty.await(); + } finally { + lock.unlock(); +@@ -549,7 +547,7 @@ + lock.lockInterruptibly(); + E result; + try { +- while ( (result = dequeue()) == null && nanos > 0) ++ while ( (result = extract()) == null && nanos > 0) + nanos = notEmpty.awaitNanos(nanos); + } finally { + lock.unlock(); +@@ -560,11 +558,13 @@ + public E peek() { + final ReentrantLock lock = this.lock; + lock.lock(); ++ E result; + try { +- return (size == 0) ? null : (E) queue[0]; ++ result = size > 0 ? (E) queue[0] : null; + } finally { + lock.unlock(); + } ++ return result; + } + + /** +@@ -648,28 +648,32 @@ + * @return {@code true} if this queue changed as a result of the call + */ + public boolean remove(Object o) { ++ boolean removed = false; + final ReentrantLock lock = this.lock; + lock.lock(); + try { + int i = indexOf(o); +- if (i == -1) +- return false; +- removeAt(i); +- return true; ++ if (i != -1) { ++ removeAt(i); ++ removed = true; ++ } + } finally { + lock.unlock(); + } ++ return removed; + } + ++ + /** + * Identity-based version for use in Itr.remove + */ +- void removeEQ(Object o) { ++ private void removeEQ(Object o) { + final ReentrantLock lock = this.lock; + lock.lock(); + try { + Object[] array = queue; +- for (int i = 0, n = size; i < n; i++) { ++ int n = size; ++ for (int i = 0; i < n; i++) { + if (o == array[i]) { + removeAt(i); + break; +@@ -689,13 +693,15 @@ + * @return {@code true} if this queue contains the specified element + */ + public boolean contains(Object o) { ++ int index; + final ReentrantLock lock = this.lock; + lock.lock(); + try { +- return indexOf(o) != -1; ++ index = indexOf(o); + } finally { + lock.unlock(); + } ++ return index != -1; + } + + /** +@@ -721,6 +727,7 @@ + } + } + ++ + public String toString() { + final ReentrantLock lock = this.lock; + lock.lock(); +@@ -731,7 +738,7 @@ + StringBuilder sb = new StringBuilder(); + sb.append('['); + for (int i = 0; i < n; ++i) { +- Object e = queue[i]; ++ E e = (E)queue[i]; + sb.append(e == this ? "(this Collection)" : e); + if (i != n - 1) + sb.append(',').append(' '); +@@ -749,7 +756,23 @@ + * @throws IllegalArgumentException {@inheritDoc} + */ + public int drainTo(Collection<? super E> c) { +- return drainTo(c, Integer.MAX_VALUE); ++ if (c == null) ++ throw new NullPointerException(); ++ if (c == this) ++ throw new IllegalArgumentException(); ++ final ReentrantLock lock = this.lock; ++ lock.lock(); ++ try { ++ int n = 0; ++ E e; ++ while ( (e = extract()) != null) { ++ c.add(e); ++ ++n; ++ } ++ return n; ++ } finally { ++ lock.unlock(); ++ } + } + + /** +@@ -768,10 +791,11 @@ + final ReentrantLock lock = this.lock; + lock.lock(); + try { +- int n = Math.min(size, maxElements); +- for (int i = 0; i < n; i++) { +- c.add((E) queue[0]); // In this order, in case add() throws. +- dequeue(); ++ int n = 0; ++ E e; ++ while (n < maxElements && (e = extract()) != null) { ++ c.add(e); ++ ++n; + } + return n; + } finally { +@@ -819,7 +843,8 @@ + * The following code can be used to dump the queue into a newly + * allocated array of {@code String}: + * +- * <pre> {@code String[] y = x.toArray(new String[0]);}</pre> ++ * <pre> ++ * String[] y = x.toArray(new String[0]);</pre> + * + * Note that {@code toArray(new Object[0])} is identical in function to + * {@code toArray()}. +@@ -872,7 +897,7 @@ + */ + final class Itr implements Iterator<E> { + final Object[] array; // Array of all elements +- int cursor; // index of next element to return ++ int cursor; // index of next element to return; + int lastRet; // index of last element, or -1 if no such + + Itr(Object[] array) { +@@ -900,18 +925,17 @@ + } + + /** +- * Saves this queue to a stream (that is, serializes it). +- * +- * For compatibility with previous version of this class, elements +- * are first copied to a java.util.PriorityQueue, which is then +- * serialized. ++ * Saves the state to a stream (that is, serializes it). For ++ * compatibility with previous version of this class, ++ * elements are first copied to a java.util.PriorityQueue, ++ * which is then serialized. + */ + private void writeObject(java.io.ObjectOutputStream s) + throws java.io.IOException { + lock.lock(); + try { +- // avoid zero capacity argument +- q = new PriorityQueue<E>(Math.max(size, 1), comparator); ++ int n = size; // avoid zero capacity argument ++ q = new PriorityQueue<E>(n == 0 ? 1 : n, comparator); + q.addAll(this); + s.defaultWriteObject(); + } finally { +@@ -921,7 +945,10 @@ + } + + /** +- * Reconstitutes this queue from a stream (that is, deserializes it). ++ * Reconstitutes the {@code PriorityBlockingQueue} instance from a stream ++ * (that is, deserializes it). ++ * ++ * @param s the stream + */ + private void readObject(java.io.ObjectInputStream s) + throws java.io.IOException, ClassNotFoundException { +--- jdk/src/share/classes/javax/swing/JComponent.java 2012-08-10 10:27:56.000000000 -0700 ++++ jdk/src/share/classes/javax/swing/JComponent.java 2012-08-19 12:39:54.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -2636,16 +2636,17 @@ + * attribute: visualUpdate true + */ + public void setVisible(boolean aFlag) { +- if (aFlag != isVisible()) { ++ if(aFlag != isVisible()) { + super.setVisible(aFlag); +- if (aFlag) { +- Container parent = getParent(); +- if (parent != null) { +- Rectangle r = getBounds(); +- parent.repaint(r.x, r.y, r.width, r.height); +- } +- revalidate(); ++ Container parent = getParent(); ++ if(parent != null) { ++ Rectangle r = getBounds(); ++ parent.repaint(r.x,r.y,r.width,r.height); + } ++ // Some (all should) LayoutManagers do not consider components ++ // that are not visible. As such we need to revalidate when the ++ // visible bit changes. ++ revalidate(); + } + } + +@@ -5563,22 +5564,4 @@ + ",preferredSize=" + preferredSizeString; + } + +- /** +- * {@inheritDoc} +- */ +- @Override +- @Deprecated +- public void hide() { +- boolean showing = isShowing(); +- super.hide(); +- if (showing) { +- Container parent = getParent(); +- if (parent != null) { +- Rectangle r = getBounds(); +- parent.repaint(r.x, r.y, r.width, r.height); +- } +- revalidate(); +- } +- } +- + } +--- jdk/src/share/classes/javax/swing/JViewport.java 2012-08-10 10:27:59.000000000 -0700 ++++ jdk/src/share/classes/javax/swing/JViewport.java 2012-08-19 12:39:54.000000000 -0700 +@@ -1586,18 +1586,10 @@ + int bdx = blitToX - blitFromX; + int bdy = blitToY - blitFromY; + +- Composite oldComposite = null; + // Shift the scrolled region +- if (g instanceof Graphics2D) { +- Graphics2D g2d = (Graphics2D) g; +- oldComposite = g2d.getComposite(); +- g2d.setComposite(AlphaComposite.Src); +- } + rm.copyArea(this, g, blitFromX, blitFromY, blitW, blitH, bdx, bdy, + false); +- if (oldComposite != null) { +- ((Graphics2D) g).setComposite(oldComposite); +- } ++ + // Paint the newly exposed region. + int x = view.getX(); + int y = view.getY(); +--- jdk/src/share/classes/javax/swing/RepaintManager.java 2012-08-10 10:28:00.000000000 -0700 ++++ jdk/src/share/classes/javax/swing/RepaintManager.java 2012-08-19 12:39:54.000000000 -0700 +@@ -119,11 +119,6 @@ + // Whether or not a VolatileImage should be used for double-buffered painting + static boolean volatileImageBufferEnabled = true; + /** +- * Type of VolatileImage which should be used for double-buffered +- * painting. +- */ +- private static final int volatileBufferType; +- /** + * Value of the system property awt.nativeDoubleBuffering. + */ + private static boolean nativeDoubleBuffering; +@@ -209,13 +204,6 @@ + ((SunGraphicsEnvironment)ge).addDisplayChangedListener( + new DisplayChangedHandler()); + } +- Toolkit tk = Toolkit.getDefaultToolkit(); +- if ((tk instanceof SunToolkit) +- && ((SunToolkit) tk).isSwingBackbufferTranslucencySupported()) { +- volatileBufferType = Transparency.TRANSLUCENT; +- } else { +- volatileBufferType = Transparency.OPAQUE; +- } + } + + /** +@@ -997,8 +985,7 @@ + if (image != null) { + image.flush(); + } +- image = config.createCompatibleVolatileImage(width, height, +- volatileBufferType); ++ image = config.createCompatibleVolatileImage(width, height); + volatileMap.put(config, image); + } + return image; +@@ -1492,26 +1479,9 @@ + for(y=clipY, maxy = clipY + clipH; y < maxy ; y += bh) { + osg.translate(-x, -y); + osg.setClip(x,y,bw,bh); +- if (volatileBufferType != Transparency.OPAQUE +- && osg instanceof Graphics2D) { +- final Graphics2D g2d = (Graphics2D) osg; +- final Color oldBg = g2d.getBackground(); +- g2d.setBackground(c.getBackground()); +- g2d.clearRect(x, y, bw, bh); +- g2d.setBackground(oldBg); +- } + c.paintToOffscreen(osg, x, y, bw, bh, maxx, maxy); + g.setClip(x, y, bw, bh); +- if (volatileBufferType != Transparency.OPAQUE +- && g instanceof Graphics2D) { +- final Graphics2D g2d = (Graphics2D) g; +- final Composite oldComposite = g2d.getComposite(); +- g2d.setComposite(AlphaComposite.Src); +- g2d.drawImage(image, x, y, c); +- g2d.setComposite(oldComposite); +- } else { +- g.drawImage(image, x, y, c); +- } ++ g.drawImage(image, x, y, c); + osg.translate(x, y); + } + } +--- jdk/src/share/classes/javax/swing/text/DefaultCaret.java 2012-08-10 10:28:13.000000000 -0700 ++++ jdk/src/share/classes/javax/swing/text/DefaultCaret.java 2012-08-19 12:39:54.000000000 -0700 +@@ -403,10 +403,6 @@ + * @see MouseListener#mouseClicked + */ + public void mouseClicked(MouseEvent e) { +- if (getComponent() == null) { +- return; +- } +- + int nclicks = SwingUtilities2.getAdjustedClickCount(getComponent(), e); + + if (! e.isConsumed()) { +--- jdk/src/share/classes/sun/awt/FontConfiguration.java 2012-08-10 10:28:23.000000000 -0700 ++++ jdk/src/share/classes/sun/awt/FontConfiguration.java 2012-08-19 12:39:55.000000000 -0700 @@ -1146,7 +1146,7 @@ */ HashMap<String, Boolean> existsMap; @@ -4557,8 +7375,8 @@ return false; } else if (existsMap == null) { existsMap = new HashMap<String, Boolean>(); ---- jdk/src/share/classes/sun/awt/OSInfo.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/awt/OSInfo.java 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/classes/sun/awt/OSInfo.java 2012-08-10 10:28:24.000000000 -0700 ++++ jdk/src/share/classes/sun/awt/OSInfo.java 2012-08-19 12:39:55.000000000 -0700 @@ -39,6 +39,7 @@ WINDOWS, LINUX, @@ -4578,8 +7396,73 @@ if (osName.contains("OS X")) { return MACOSX; } ---- jdk/src/share/classes/sun/font/FontUtilities.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/font/FontUtilities.java 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/classes/sun/awt/SunToolkit.java 2012-08-10 10:28:24.000000000 -0700 ++++ jdk/src/share/classes/sun/awt/SunToolkit.java 2012-08-19 12:39:55.000000000 -0700 +@@ -1976,13 +1976,6 @@ + } + + /** +- * Returns true if swing backbuffer should be translucent. +- */ +- public boolean isSwingBackbufferTranslucencySupported() { +- return false; +- } +- +- /** + * Returns whether or not a containing top level window for the passed + * component is + * {@link GraphicsDevice.WindowTranslucency#PERPIXEL_TRANSLUCENT PERPIXEL_TRANSLUCENT}. +@@ -2103,41 +2096,25 @@ + private EventQueueItem queueTail = null; + private final EventQueue eventQueue; + +- // For the case when queue is cleared but events are not posted +- private volatile boolean isFlushing = false; +- + PostEventQueue(EventQueue eq) { + eventQueue = eq; + } + + public synchronized boolean noEvents() { +- return queueHead == null && !isFlushing; ++ return queueHead == null; + } + + /* + * Continually post pending AWTEvents to the Java EventQueue. The method + * is synchronized to ensure the flush is completed before a new event + * can be posted to this queue. +- * +- * 7177040: The method couldn't be wholly synchronized because of calls +- * of EventQueue.postEvent() that uses pushPopLock, otherwise it could +- * potentially lead to deadlock + */ +- public void flush() { +- EventQueueItem tempQueue; +- synchronized (this) { +- tempQueue = queueHead; +- queueHead = queueTail = null; +- isFlushing = (tempQueue != null); +- } +- try { +- while (tempQueue != null) { +- eventQueue.postEvent(tempQueue.event); +- tempQueue = tempQueue.next; +- } +- } +- finally { +- isFlushing = false; ++ public synchronized void flush() { ++ EventQueueItem tempQueue = queueHead; ++ queueHead = queueTail = null; ++ while (tempQueue != null) { ++ eventQueue.postEvent(tempQueue.event); ++ tempQueue = tempQueue.next; + } + } + +--- jdk/src/share/classes/sun/font/FontUtilities.java 2012-08-10 10:28:29.000000000 -0700 ++++ jdk/src/share/classes/sun/font/FontUtilities.java 2012-08-19 12:39:55.000000000 -0700 @@ -48,6 +48,8 @@ public static boolean isLinux; @@ -4601,8 +7484,8 @@ isMacOSX = osName.contains("OS X"); // TODO: MacOSX String t2kStr = System.getProperty("sun.java2d.font.scaler"); ---- jdk/src/share/classes/sun/font/SunFontManager.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/font/SunFontManager.java 2012-05-17 16:14:57.000000000 -0700 +--- jdk/src/share/classes/sun/font/SunFontManager.java 2012-08-10 10:28:31.000000000 -0700 ++++ jdk/src/share/classes/sun/font/SunFontManager.java 2012-08-19 12:39:55.000000000 -0700 @@ -417,7 +417,7 @@ * registerFonts method as on-screen these JRE fonts * always go through the T2K rasteriser. @@ -4612,9 +7495,106 @@ /* Linux font configuration uses these fonts */ registerFontDir(jreFontDirName); } ---- jdk/src/share/classes/sun/print/PSPrinterJob.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/print/PSPrinterJob.java 2012-05-17 16:18:00.000000000 -0700 -@@ -1536,7 +1536,7 @@ +--- jdk/src/share/classes/sun/nio/ch/DatagramChannelImpl.java 2012-08-10 10:29:03.000000000 -0700 ++++ jdk/src/share/classes/sun/nio/ch/DatagramChannelImpl.java 2012-08-19 12:39:56.000000000 -0700 +@@ -749,8 +749,7 @@ + if (sm != null) + sm.checkConnect(isa.getAddress().getHostAddress(), + isa.getPort()); +- boolean isIPv6 = (family == StandardProtocolFamily.INET6); +- disconnect0(fd, isIPv6); ++ disconnect0(fd); + remoteAddress = null; + state = ST_UNCONNECTED; + +@@ -1085,7 +1084,7 @@ + + private static native void initIDs(); + +- private static native void disconnect0(FileDescriptor fd, boolean isIPv6) ++ private static native void disconnect0(FileDescriptor fd) + throws IOException; + + private native int receive0(FileDescriptor fd, long address, int len, +--- jdk/src/share/classes/sun/nio/ch/IOUtil.java 2012-08-10 10:29:03.000000000 -0700 ++++ jdk/src/share/classes/sun/nio/ch/IOUtil.java 2012-08-19 12:39:56.000000000 -0700 +@@ -36,11 +36,6 @@ + + class IOUtil { + +- /** +- * Max number of iovec structures that readv/writev supports +- */ +- static final int IOV_MAX; +- + private IOUtil() { } // No instantiation + + static int write(FileDescriptor fd, ByteBuffer src, long position, +@@ -116,8 +111,7 @@ + + // Iterate over buffers to populate native iovec array. + int count = offset + length; +- int i = offset; +- while (i < count && iov_len < IOV_MAX) { ++ for (int i=offset; i<count; i++) { + ByteBuffer buf = bufs[i]; + int pos = buf.position(); + int lim = buf.limit(); +@@ -141,7 +135,6 @@ + vec.putLen(iov_len, rem); + iov_len++; + } +- i++; + } + if (iov_len == 0) + return 0L; +@@ -247,8 +240,7 @@ + + // Iterate over buffers to populate native iovec array. + int count = offset + length; +- int i = offset; +- while (i < count && iov_len < IOV_MAX) { ++ for (int i=offset; i<count; i++) { + ByteBuffer buf = bufs[i]; + if (buf.isReadOnly()) + throw new IllegalArgumentException("Read-only buffer"); +@@ -272,7 +264,6 @@ + vec.putLen(iov_len, rem); + iov_len++; + } +- i++; + } + if (iov_len == 0) + return 0L; +@@ -342,14 +333,11 @@ + + static native void setfdVal(FileDescriptor fd, int value); + +- static native int iovMax(); +- + static native void initIDs(); + + static { + // Note that IOUtil.initIDs is called from within Util.load. + Util.load(); +- IOV_MAX = iovMax(); + } + + } +--- jdk/src/share/classes/sun/nio/ch/Util.java 2012-08-10 10:29:04.000000000 -0700 ++++ jdk/src/share/classes/sun/nio/ch/Util.java 2012-08-19 12:39:56.000000000 -0700 +@@ -45,7 +45,7 @@ + // -- Caches -- + + // The number of temp buffers in our pool +- private static final int TEMP_BUF_POOL_SIZE = IOUtil.IOV_MAX; ++ private static final int TEMP_BUF_POOL_SIZE = 8; + + // Per-thread cache of temporary direct buffers + private static ThreadLocal<BufferCache> bufferCache = +--- jdk/src/share/classes/sun/print/PSPrinterJob.java 2012-08-10 10:29:08.000000000 -0700 ++++ jdk/src/share/classes/sun/print/PSPrinterJob.java 2012-08-19 12:39:56.000000000 -0700 +@@ -1537,7 +1537,7 @@ } String osname = System.getProperty("os.name"); @@ -4623,8 +7603,8 @@ execCmd = new String[ncomps]; execCmd[n++] = "/usr/bin/lpr"; if ((pFlags & PRINTER) != 0) { ---- jdk/src/share/classes/sun/security/jgss/wrapper/SunNativeProvider.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/security/jgss/wrapper/SunNativeProvider.java 2012-05-20 10:08:29.000000000 -0700 +--- jdk/src/share/classes/sun/security/jgss/wrapper/SunNativeProvider.java 2012-08-10 10:29:20.000000000 -0700 ++++ jdk/src/share/classes/sun/security/jgss/wrapper/SunNativeProvider.java 2012-08-19 12:39:57.000000000 -0700 @@ -83,7 +83,8 @@ String osname = System.getProperty("os.name"); if (osname.startsWith("SunOS")) { @@ -4635,16 +7615,65 @@ gssLibs = new String[]{ "libgssapi.so", "libgssapi_krb5.so", ---- jdk/src/share/classes/sun/tools/attach/META-INF/services/com.sun.tools.attach.spi.AttachProvider 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/tools/attach/META-INF/services/com.sun.tools.attach.spi.AttachProvider 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/classes/sun/swing/FilePane.java 2012-08-10 10:29:34.000000000 -0700 ++++ jdk/src/share/classes/sun/swing/FilePane.java 2012-08-19 12:39:57.000000000 -0700 +@@ -35,7 +35,6 @@ + import java.util.List; + import java.util.concurrent.Callable; + +-import javax.accessibility.AccessibleContext; + import javax.swing.*; + import javax.swing.border.*; + import javax.swing.event.*; +@@ -83,9 +82,6 @@ + private JPanel currentViewPanel; + private String[] viewTypeActionNames; + +- private String filesListAccessibleName = null; +- private String filesDetailsAccessibleName = null; +- + private JPopupMenu contextMenu; + private JMenu viewMenu; + +@@ -454,9 +450,6 @@ + gigaByteString = UIManager.getString("FileChooser.fileSizeGigaBytes", l); + fullRowSelection = UIManager.getBoolean("FileView.fullRowSelection"); + +- filesListAccessibleName = UIManager.getString("FileChooser.filesListAccessibleName", l); +- filesDetailsAccessibleName = UIManager.getString("FileChooser.filesDetailsAccessibleName", l); +- + renameErrorTitleText = UIManager.getString("FileChooser.renameErrorTitleText", l); + renameErrorText = UIManager.getString("FileChooser.renameErrorText", l); + renameErrorFileExistsText = UIManager.getString("FileChooser.renameErrorFileExistsText", l); +@@ -641,9 +634,6 @@ + if (listViewBorder != null) { + scrollpane.setBorder(listViewBorder); + } +- +- list.putClientProperty(AccessibleContext.ACCESSIBLE_NAME_PROPERTY, filesListAccessibleName); +- + p.add(scrollpane, BorderLayout.CENTER); + return p; + } +@@ -1238,8 +1228,6 @@ + + detailsTableModel.fireTableStructureChanged(); + +- detailsTable.putClientProperty(AccessibleContext.ACCESSIBLE_NAME_PROPERTY, filesDetailsAccessibleName); +- + return p; + } // createDetailsView + +--- jdk/src/share/classes/sun/tools/attach/META-INF/services/com.sun.tools.attach.spi.AttachProvider 2012-08-10 10:29:42.000000000 -0700 ++++ jdk/src/share/classes/sun/tools/attach/META-INF/services/com.sun.tools.attach.spi.AttachProvider 2012-08-19 12:39:58.000000000 -0700 @@ -30,4 +30,5 @@ #[solaris]sun.tools.attach.SolarisAttachProvider #[windows]sun.tools.attach.WindowsAttachProvider #[linux]sun.tools.attach.LinuxAttachProvider +#[bsd]sun.tools.attach.BsdAttachProvider #[macosx]sun.tools.attach.BsdAttachProvider ---- jdk/src/share/classes/sun/tools/jar/Main.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/tools/jar/Main.java 2011-04-22 23:08:32.000000000 -0700 +--- jdk/src/share/classes/sun/tools/jar/Main.java 2012-08-10 10:29:42.000000000 -0700 ++++ jdk/src/share/classes/sun/tools/jar/Main.java 2012-08-19 12:39:58.000000000 -0700 @@ -51,6 +51,7 @@ String zname = ""; String[] files; @@ -4715,8 +7744,8 @@ if (!d.exists() && !d.mkdirs() || !d.isDirectory()) { throw new IOException(formatMsg( "error.create.dir", d.getPath())); ---- jdk/src/share/classes/sun/tools/jar/resources/jar.properties 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/classes/sun/tools/jar/resources/jar.properties 2011-04-22 23:08:32.000000000 -0700 +--- jdk/src/share/classes/sun/tools/jar/resources/jar.properties 2012-08-10 10:29:42.000000000 -0700 ++++ jdk/src/share/classes/sun/tools/jar/resources/jar.properties 2012-08-19 12:39:58.000000000 -0700 @@ -44,6 +44,8 @@ {0} : could not create directory error.incorrect.length=\ @@ -4726,8 +7755,8 @@ out.added.manifest=\ added manifest out.update.manifest=\ ---- jdk/src/share/demo/jvmti/compiledMethodLoad/sample.makefile.txt 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/demo/jvmti/compiledMethodLoad/sample.makefile.txt 2011-04-22 23:08:34.000000000 -0700 +--- jdk/src/share/demo/jvmti/compiledMethodLoad/sample.makefile.txt 2012-08-10 10:30:07.000000000 -0700 ++++ jdk/src/share/demo/jvmti/compiledMethodLoad/sample.makefile.txt 2012-08-19 12:39:59.000000000 -0700 @@ -38,6 +38,7 @@ # gnumake JDK=<java_home> OSNAME=solaris [OPT=true] [LIBARCH=sparcv9] # gnumake JDK=<java_home> OSNAME=linux [OPT=true] @@ -4766,8 +7795,8 @@ # Common -I options CFLAGS += -I. CFLAGS += -I../agent_util ---- jdk/src/share/native/com/sun/java/util/jar/pack/defines.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/com/sun/java/util/jar/pack/defines.h 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/native/com/sun/java/util/jar/pack/defines.h 2012-08-10 10:30:16.000000000 -0700 ++++ jdk/src/share/native/com/sun/java/util/jar/pack/defines.h 2012-08-19 12:39:59.000000000 -0700 @@ -93,7 +93,7 @@ // bytes and byte arrays @@ -4777,8 +7806,8 @@ #ifdef _LP64 typedef unsigned int uLong; // Historical zlib, should be 32-bit. #else ---- jdk/src/share/native/com/sun/media/sound/SoundDefs.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/com/sun/media/sound/SoundDefs.h 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/native/com/sun/media/sound/SoundDefs.h 2012-08-10 10:30:18.000000000 -0700 ++++ jdk/src/share/native/com/sun/media/sound/SoundDefs.h 2012-08-19 12:39:59.000000000 -0700 @@ -64,7 +64,7 @@ @@ -4788,8 +7817,8 @@ #include <sys/types.h> #endif ---- jdk/src/share/native/java/lang/fdlibm/include/fdlibm.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/java/lang/fdlibm/include/fdlibm.h 2012-05-17 16:18:00.000000000 -0700 +--- jdk/src/share/native/java/lang/fdlibm/include/fdlibm.h 2012-08-10 10:30:19.000000000 -0700 ++++ jdk/src/share/native/java/lang/fdlibm/include/fdlibm.h 2012-08-19 12:39:59.000000000 -0700 @@ -24,6 +24,9 @@ * questions. */ @@ -4813,8 +7842,8 @@ #ifdef __NEWVALID /* special setup for Sun test regime */ #if defined(i386) || defined(i486) || \ defined(intel) || defined(x86) || defined(arm) || \ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv2x2_f.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv2x2_f.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv2x2_f.c 2012-08-10 10:30:27.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv2x2_f.c 2012-08-19 12:39:59.000000000 -0700 @@ -86,7 +86,7 @@ #endif /* MLIB_USE_FTOI_CLAMPING */ @@ -4854,8 +7883,8 @@ #endif /* _NO_LONGLONG */ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16ext.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16ext.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16ext.c 2012-08-10 10:30:27.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16ext.c 2012-08-19 12:39:59.000000000 -0700 @@ -126,7 +126,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -4895,8 +7924,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16nw.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16nw.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16nw.c 2012-08-10 10:30:27.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_16nw.c 2012-08-19 12:39:59.000000000 -0700 @@ -94,7 +94,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -4936,8 +7965,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8ext.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8ext.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8ext.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8ext.c 2012-08-19 12:39:59.000000000 -0700 @@ -126,7 +126,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -4977,8 +8006,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8nw.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8nw.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8nw.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_8nw.c 2012-08-19 12:39:59.000000000 -0700 @@ -95,7 +95,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -5018,8 +8047,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16ext.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16ext.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16ext.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16ext.c 2012-08-19 12:39:59.000000000 -0700 @@ -126,7 +126,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -5059,8 +8088,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16nw.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16nw.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16nw.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageConv_u16nw.c 2012-08-19 12:39:59.000000000 -0700 @@ -94,7 +94,7 @@ #define D2I(x) CLAMP_S32((x) SAT_OFF) @@ -5100,8 +8129,8 @@ #endif /* _NO_LONGLONG */ /***************************************************************/ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageCopy_Bit.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageCopy_Bit.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageCopy_Bit.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageCopy_Bit.c 2012-08-19 12:39:59.000000000 -0700 @@ -95,7 +95,7 @@ dst = dp[0]; if (ld_offset + size < 32) { @@ -5321,8 +8350,8 @@ } #else /* _LONGLONG */ ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_64.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_64.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_64.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_64.c 2012-08-19 12:39:59.000000000 -0700 @@ -168,7 +168,7 @@ } @@ -5603,8 +8632,8 @@ dp[12] = t0; dp[13] = t1; dp[14] = t2; ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_Bit.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_Bit.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_Bit.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageLookUp_Bit.c 2012-08-19 12:39:59.000000000 -0700 @@ -88,7 +88,7 @@ } d64_2_f32; @@ -5756,8 +8785,8 @@ ((mlib_u32*)lh)[0] = l; ((mlib_u32*)lh)[1] = l; ((mlib_u32*)lh)[2] = l; ((mlib_u32*)lh)[3] = h; ---- jdk/src/share/native/sun/awt/medialib/mlib_ImageUtils.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_ImageUtils.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_ImageUtils.c 2012-08-10 10:30:28.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_ImageUtils.c 2012-08-19 12:39:59.000000000 -0700 @@ -30,7 +30,7 @@ typedef union { mlib_d64 db; @@ -5767,8 +8796,8 @@ mlib_s32 int1, int0; #else mlib_s32 int0, int1; ---- jdk/src/share/native/sun/awt/medialib/mlib_c_ImageCopy.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_c_ImageCopy.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_c_ImageCopy.c 2012-08-10 10:30:29.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_c_ImageCopy.c 2012-08-19 12:39:59.000000000 -0700 @@ -275,11 +275,11 @@ for (i = 0; j <= (b_size - 4); j += 4, i++) { src0 = src1; @@ -5867,8 +8896,8 @@ s0 = s1; dp += SIZE; sp += SIZE; ---- jdk/src/share/native/sun/awt/medialib/mlib_c_ImageLookUp_f.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_c_ImageLookUp_f.c 2011-04-22 23:08:36.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_c_ImageLookUp_f.c 2012-08-10 10:30:29.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_c_ImageLookUp_f.c 2012-08-19 12:39:59.000000000 -0700 @@ -120,7 +120,7 @@ } \ } @@ -7101,8 +10130,8 @@ dp[12] = t0; dp[13] = t1; dp[14] = t2; ---- jdk/src/share/native/sun/awt/medialib/mlib_image.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_image.h 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_image.h 2012-08-10 10:30:29.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_image.h 2012-08-19 12:39:59.000000000 -0700 @@ -27,9 +27,21 @@ #ifndef MLIB_IMAGE_H #define MLIB_IMAGE_H @@ -7126,8 +10155,8 @@ #include <mlib_types.h> #include <mlib_status.h> #include <mlib_sys.h> ---- jdk/src/share/native/sun/awt/medialib/mlib_sys.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_sys.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/share/native/sun/awt/medialib/mlib_sys.c 2012-08-10 10:30:30.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_sys.c 2012-08-19 12:39:59.000000000 -0700 @@ -26,7 +26,7 @@ #include <stdlib.h> @@ -7149,19 +10178,58 @@ return valloc(size); #else return (void *) memalign(8, size); ---- jdk/src/share/native/sun/awt/medialib/mlib_types.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/awt/medialib/mlib_types.h 2012-05-17 16:18:01.000000000 -0700 -@@ -59,7 +59,7 @@ +--- jdk/src/share/native/sun/awt/medialib/mlib_types.h 2012-08-10 10:30:30.000000000 -0700 ++++ jdk/src/share/native/sun/awt/medialib/mlib_types.h 2012-08-19 12:39:59.000000000 -0700 +@@ -59,8 +59,16 @@ #if defined(__SUNPRO_C) || defined(__SUNPRO_CC) || defined(__GNUC__) --#if defined(MACOSX) +#if defined(_ALLBSD_SOURCE) #include <stddef.h> /* for ptrdiff_t */ #include <stdint.h> /* for uintptr_t */ - #elif defined(__linux__) ---- jdk/src/share/native/sun/java2d/opengl/OGLFuncs.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/share/native/sun/java2d/opengl/OGLFuncs.h 2012-05-17 16:18:01.000000000 -0700 ++#elif defined(__linux__) ++#include <stdint.h> /* for uintptr_t */ ++#include <malloc.h> /* for ptrdiff_t */ ++#else ++#include <link.h> /* for uintptr_t */ ++#include <stddef.h> /* for ptrdiff_t */ ++#endif /* __linux__ */ + + #if defined(MLIB_OS64BIT) || (defined(MACOSX) && defined(_LP64)) + +--- jdk/src/share/native/sun/java2d/opengl/OGLBlitLoops.c 2012-08-10 10:31:05.000000000 -0700 ++++ jdk/src/share/native/sun/java2d/opengl/OGLBlitLoops.c 2012-08-19 12:40:00.000000000 -0700 +@@ -393,16 +393,7 @@ + OGLSDOps *dstOps, + jint dx1, jint dy1, jint dx2, jint dy2) + { +- jboolean adjustAlpha = (pf != NULL && !pf->hasAlpha); + j2d_glBindTexture(dstOps->textureTarget, dstOps->textureID); +- +- if (adjustAlpha) { +- // if the source surface does not have an alpha channel, +- // we need to ensure that the alpha values are forced to 1.0f +- j2d_glPixelTransferf(GL_ALPHA_SCALE, 0.0f); +- j2d_glPixelTransferf(GL_ALPHA_BIAS, 1.0f); +- } +- + // in case pixel stride is not a multiple of scanline stride the copy + // has to be done line by line (see 6207877) + if (srcInfo->scanStride % srcInfo->pixelStride != 0) { +@@ -422,11 +413,6 @@ + dx1, dy1, dx2-dx1, dy2-dy1, + pf->format, pf->type, srcInfo->rasBase); + } +- if (adjustAlpha) { +- // restore scale/bias to their original values +- j2d_glPixelTransferf(GL_ALPHA_SCALE, 1.0f); +- j2d_glPixelTransferf(GL_ALPHA_BIAS, 0.0f); +- } + } + + /** +--- jdk/src/share/native/sun/java2d/opengl/OGLFuncs.h 2012-08-10 10:31:05.000000000 -0700 ++++ jdk/src/share/native/sun/java2d/opengl/OGLFuncs.h 2012-08-19 12:40:00.000000000 -0700 @@ -26,7 +26,7 @@ #ifndef OGLFuncs_h_Included #define OGLFuncs_h_Included @@ -7171,8 +10239,8 @@ #include <dlfcn.h> #endif #include "jni.h" ---- jdk/src/solaris/back/util_md.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/back/util_md.h 2012-05-17 16:14:59.000000000 -0700 +--- jdk/src/solaris/back/util_md.h 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/back/util_md.h 2012-08-19 12:40:00.000000000 -0700 @@ -51,7 +51,7 @@ /* On little endian machines, convert java big endian numbers. */ @@ -7182,8 +10250,8 @@ #define HOST_TO_JAVA_CHAR(x) (((x & 0xff) << 8) | ((x >> 8) & (0xff))) #define HOST_TO_JAVA_SHORT(x) (((x & 0xff) << 8) | ((x >> 8) & (0xff))) ---- jdk/src/solaris/bin/ergo.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/bin/ergo.c 2012-05-20 12:17:44.000000000 -0700 +--- jdk/src/solaris/bin/ergo.c 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/bin/ergo.c 2012-08-19 12:40:00.000000000 -0700 @@ -100,6 +100,27 @@ /* Compute physical memory by asking the OS */ uint64_t @@ -7218,8 +10286,8 @@ return result; +#endif } ---- jdk/src/solaris/bin/ergo.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/bin/ergo.h 2012-05-17 16:14:59.000000000 -0700 +--- jdk/src/solaris/bin/ergo.h 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/bin/ergo.h 2012-08-19 12:40:00.000000000 -0700 @@ -33,6 +33,10 @@ #include <sys/stat.h> #include <unistd.h> @@ -7231,8 +10299,8 @@ #include "java.h" ---- jdk/src/solaris/bin/ergo_i586.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/bin/ergo_i586.c 2012-05-20 12:18:55.000000000 -0700 +--- jdk/src/solaris/bin/ergo_i586.c 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/bin/ergo_i586.c 2012-08-19 12:40:00.000000000 -0700 @@ -106,7 +106,7 @@ #endif /* __solaris__ */ @@ -7291,8 +10359,8 @@ return result; +#endif } ---- jdk/src/solaris/bin/java_md_solinux.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/bin/java_md_solinux.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/bin/java_md_solinux.c 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/bin/java_md_solinux.c 2012-08-19 12:40:00.000000000 -0700 @@ -951,6 +951,19 @@ return exec_path; } @@ -7313,17 +10381,48 @@ /* --- Splash Screen shared library support --- */ static const char* SPLASHSCREEN_SO = JNI_LIB_NAME("splashscreen"); static void* hSplashLib = NULL; -@@ -982,7 +995,7 @@ +@@ -982,18 +995,7 @@ int ContinueInNewThread0(int (JNICALL *continuation)(void *), jlong stack_size, void * args) { int rslt; --#ifdef __linux__ +-#ifdef __solaris__ +- thread_t tid; +- long flags = 0; +- if (thr_create(NULL, stack_size, (void *(*)(void *))continuation, args, flags, &tid) == 0) { +- void * tmp; +- thr_join(tid, NULL, &tmp); +- rslt = (int)tmp; +- } else { +- /* See below. Continue in current thread if thr_create() failed */ +- rslt = continuation(args); +- } +-#else /* ! __solaris__ */ +#if !defined(MACOSX) && (defined(__linux__) || defined(_ALLBSD_SOURCE)) pthread_t tid; pthread_attr_t attr; pthread_attr_init(&attr); ---- jdk/src/solaris/bin/java_md_solinux.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/bin/java_md_solinux.h 2012-05-20 10:43:26.000000000 -0700 +@@ -1018,7 +1020,18 @@ + } + + pthread_attr_destroy(&attr); +-#endif /* __solaris__ */ ++#else /* ! __linux__ */ ++ thread_t tid; ++ long flags = 0; ++ if (thr_create(NULL, stack_size, (void *(*)(void *))continuation, args, flags, &tid) == 0) { ++ void * tmp; ++ thr_join(tid, NULL, &tmp); ++ rslt = (int)tmp; ++ } else { ++ /* See above. Continue in current thread if thr_create() failed */ ++ rslt = continuation(args); ++ } ++#endif /* __linux__ */ + return rslt; + } + +--- jdk/src/solaris/bin/java_md_solinux.h 2012-08-10 10:31:14.000000000 -0700 ++++ jdk/src/solaris/bin/java_md_solinux.h 2012-08-19 12:40:00.000000000 -0700 @@ -33,6 +33,10 @@ #include <sys/time.h> #define CounterGet() (gethrtime()/1000) @@ -7335,7 +10434,7 @@ #else /* ! HAVE_GETHRTIME */ #define CounterGet() (0) #define Counter2Micros(counts) (1) -@@ -48,13 +52,16 @@ +@@ -48,16 +52,19 @@ #ifdef __linux__ static const char *system_dir = "/usr/java"; static const char *user_dir = "/java"; @@ -7348,13 +10447,61 @@ #endif #include <dlfcn.h> --#ifdef __linux__ +-#ifdef __solaris__ +-#include <thread.h> +-#else +#if defined(__linux__) || defined(_ALLBSD_SOURCE) #include <pthread.h> - #else - #include <thread.h> ---- jdk/src/solaris/classes/sun/awt/X11FontManager.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/classes/sun/awt/X11FontManager.java 2011-04-22 23:08:38.000000000 -0700 ++#else ++#include <thread.h> + #endif + + #define JVM_DLL "libjvm.so" +--- jdk/src/solaris/classes/sun/awt/X11/XTextAreaPeer.java 2012-08-10 10:31:19.000000000 -0700 ++++ jdk/src/solaris/classes/sun/awt/X11/XTextAreaPeer.java 2012-08-19 12:40:00.000000000 -0700 +@@ -105,6 +105,7 @@ + this.target = target; + + //ComponentAccessor.enableEvents(target,AWTEvent.MOUSE_WHEEL_EVENT_MASK); ++ target.enableInputMethods(true); + + firstChangeSkipped = false; + String text = ((TextArea)target).getText(); +@@ -112,6 +113,7 @@ + jtext.setWrapStyleWord(true); + jtext.getDocument().addDocumentListener(jtext); + XToolkit.specialPeerMap.put(jtext,this); ++ jtext.enableInputMethods(true); + textPane = new AWTTextPane(jtext,this, target.getParent()); + + setBounds(x, y, width, height, SET_BOUNDS); +@@ -464,6 +466,13 @@ + + protected boolean setTextImpl(String txt) { + if (jtext != null) { ++ // Please note that we do not want to post an event ++ // if setText() replaces an empty text by an empty text, ++ // that is, if component's text remains unchanged. ++ if (jtext.getDocument().getLength() == 0 && txt.length() == 0) { ++ return true; ++ } ++ + // JTextArea.setText() posts two different events (remove & insert). + // Since we make no differences between text events, + // the document listener has to be disabled while +--- jdk/src/solaris/classes/sun/awt/X11/XTextFieldPeer.java 2012-08-10 10:31:19.000000000 -0700 ++++ jdk/src/solaris/classes/sun/awt/X11/XTextFieldPeer.java 2012-08-19 12:40:00.000000000 -0700 +@@ -73,6 +73,8 @@ + xtext = new XAWTTextField(text,this, target.getParent()); + xtext.getDocument().addDocumentListener(xtext); + xtext.setCursor(target.getCursor()); ++ target.enableInputMethods(true); ++ xtext.enableInputMethods(true); + XToolkit.specialPeerMap.put(xtext,this); + + TextField txt = (TextField) target; +--- jdk/src/solaris/classes/sun/awt/X11FontManager.java 2012-08-10 10:31:20.000000000 -0700 ++++ jdk/src/solaris/classes/sun/awt/X11FontManager.java 2012-08-19 12:40:00.000000000 -0700 @@ -213,7 +213,7 @@ if (fontID != null) { fileName = (String)fontNameMap.get(fontID); @@ -7382,8 +10529,8 @@ (!mFontConfig.foundOsSpecificFile() || !mFontConfig.fontFilesArePresent()) || (FontUtilities.isSolaris && !mFontConfig.fontFilesArePresent()))) { ---- jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java 2012-08-19 12:40:01.000000000 -0700 @@ -68,7 +68,7 @@ return createProvider("sun.nio.fs.SolarisFileSystemProvider"); if (osname.equals("Linux")) @@ -7393,9 +10540,439 @@ return createProvider("sun.nio.fs.BsdFileSystemProvider"); throw new AssertionError("Platform not recognized"); } ---- jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java 2012-05-17 16:18:01.000000000 -0700 -@@ -120,6 +120,7 @@ +--- jdk/src/solaris/classes/sun/nio/fs/LinuxUserDefinedFileAttributeView.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/LinuxUserDefinedFileAttributeView.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -55,7 +55,7 @@ + name = USER_NAMESPACE + name; + byte[] bytes = name.getBytes(); + if (bytes.length > XATTR_NAME_MAX) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "'" + name + "' is too big"); + } + return bytes; +@@ -116,7 +116,7 @@ + buffer = NativeBuffers.getNativeBuffer(size); + continue; + } +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to get list of extended attributes: " + + x.getMessage()); + } +@@ -138,7 +138,7 @@ + // fgetxattr returns size if called with size==0 + return fgetxattr(fd, nameAsBytes(file,name), 0L, 0); + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to get size of extended attribute '" + name + + "': " + x.getMessage()); + } finally { +@@ -191,7 +191,7 @@ + } catch (UnixException x) { + String msg = (x.errno() == ERANGE) ? + "Insufficient space in buffer" : x.getMessage(); +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Error reading extended attribute '" + name + "': " + msg); + } finally { + close(fd); +@@ -243,7 +243,7 @@ + src.position(pos + rem); + return rem; + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Error writing extended attribute '" + name + "': " + + x.getMessage()); + } finally { +@@ -264,7 +264,7 @@ + try { + fremovexattr(fd, nameAsBytes(file,name)); + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to delete extended attribute '" + name + "': " + x.getMessage()); + } finally { + close(fd); +--- jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -243,7 +243,7 @@ + return x.asIOException(dir); + } + if (!attrs.isDirectory()) { +- return new NotDirectoryException(dir.getPathForExceptionMessage()); ++ return new NotDirectoryException(dir.getPathForExecptionMessage()); + } + + // register with inotify (replaces existing mask if already registered) +--- jdk/src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -324,7 +324,7 @@ + return decode(address, n); + } catch (UnixException x) { + if ((x.errno() == ENOSYS) || !isAclsEnabled(fd)) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, x.getMessage() + " (file system does not support NFSv4 ACLs)"); + } + x.rethrowAsIOException(file); +@@ -355,7 +355,7 @@ + facl(fd, ACE_SETACL, n, address); + } catch (UnixException x) { + if ((x.errno() == ENOSYS) || !isAclsEnabled(fd)) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, x.getMessage() + " (file system does not support NFSv4 ACLs)"); + } + if (x.errno() == EINVAL && (n < 3)) +--- jdk/src/solaris/classes/sun/nio/fs/SolarisUserDefinedFileAttributeView.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/SolarisUserDefinedFileAttributeView.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -49,7 +49,7 @@ + if (bytes.length <= 1 || + (bytes.length == 2 && bytes[1] == '.')) + { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "'" + name + "' is not a valid name"); + } + } +@@ -96,7 +96,7 @@ + } + return Collections.unmodifiableList(list); + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to get list of extended attributes: " + + x.getMessage()); + } +@@ -126,7 +126,7 @@ + close(afd); + } + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to get size of extended attribute '" + name + + "': " + x.getMessage()); + } +@@ -165,7 +165,7 @@ + fc.close(); + } + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to read extended attribute '" + name + + "': " + x.getMessage()); + } +@@ -201,7 +201,7 @@ + fc.close(); + } + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to write extended attribute '" + name + + "': " + x.getMessage()); + } +@@ -224,7 +224,7 @@ + close(dfd); + } + } catch (UnixException x) { +- throw new FileSystemException(file.getPathForExceptionMessage(), ++ throw new FileSystemException(file.getPathForExecptionMessage(), + null, "Unable to delete extended attribute '" + name + + "': " + x.getMessage()); + } finally { +--- jdk/src/solaris/classes/sun/nio/fs/SolarisWatchService.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/SolarisWatchService.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -288,7 +288,7 @@ + return x.asIOException(dir); + } + if (!attrs.isDirectory()) { +- return new NotDirectoryException(dir.getPathForExceptionMessage()); ++ return new NotDirectoryException(dir.getPathForExecptionMessage()); + } + + // return existing watch key after updating events if already +--- jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java 2012-08-19 12:40:01.000000000 -0700 +@@ -36,6 +36,8 @@ + import sun.misc.SharedSecrets; + import sun.misc.JavaIOFileDescriptorAccess; + ++import com.sun.nio.file.ExtendedOpenOption; ++ + import static sun.nio.fs.UnixNativeDispatcher.*; + import static sun.nio.fs.UnixConstants.*; + +@@ -84,13 +86,13 @@ + } + continue; + } +- if (option == LinkOption.NOFOLLOW_LINKS && supportsNoFollowLinks()) { ++ if (option == LinkOption.NOFOLLOW_LINKS) { + flags.noFollowLinks = true; + continue; + } + if (option == null) + throw new NullPointerException(); +- throw new UnsupportedOperationException(option + " not supported"); ++ throw new UnsupportedOperationException(); + } + return flags; + } +@@ -218,15 +220,6 @@ + // follow links by default + boolean followLinks = true; + if (!flags.createNew && (flags.noFollowLinks || flags.deleteOnClose)) { +- if (flags.deleteOnClose && !supportsNoFollowLinks()) { +- try { +- if (UnixFileAttributes.get(path, false).isSymbolicLink()) +- throw new UnixException("DELETE_ON_CLOSE specified and file is a symbolic link"); +- } catch (UnixException x) { +- if (!flags.create || x.errno() != ENOENT) +- throw x; +- } +- } + followLinks = false; + oflags |= O_NOFOLLOW; + } +--- jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -383,8 +383,8 @@ + } catch (UnixException x) { + if (x.errno() == EXDEV) { + throw new AtomicMoveNotSupportedException( +- source.getPathForExceptionMessage(), +- target.getPathForExceptionMessage(), ++ source.getPathForExecptionMessage(), ++ target.getPathForExecptionMessage(), + x.errorString()); + } + x.rethrowAsIOException(source, target); +@@ -420,7 +420,7 @@ + return; // nothing to do as files are identical + if (!flags.replaceExisting) { + throw new FileAlreadyExistsException( +- target.getPathForExceptionMessage()); ++ target.getPathForExecptionMessage()); + } + + // attempt to delete target +@@ -436,7 +436,7 @@ + (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) + { + throw new DirectoryNotEmptyException( +- target.getPathForExceptionMessage()); ++ target.getPathForExecptionMessage()); + } + x.rethrowAsIOException(target); + } +@@ -489,7 +489,7 @@ + (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) + { + throw new DirectoryNotEmptyException( +- source.getPathForExceptionMessage()); ++ source.getPathForExecptionMessage()); + } + x.rethrowAsIOException(source); + } +@@ -542,7 +542,7 @@ + return; // nothing to do as files are identical + if (!flags.replaceExisting) + throw new FileAlreadyExistsException( +- target.getPathForExceptionMessage()); ++ target.getPathForExecptionMessage()); + try { + if (targetAttrs.isDirectory()) { + rmdir(target); +@@ -555,7 +555,7 @@ + (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) + { + throw new DirectoryNotEmptyException( +- target.getPathForExceptionMessage()); ++ target.getPathForExecptionMessage()); + } + x.rethrowAsIOException(target); + } +--- jdk/src/solaris/classes/sun/nio/fs/UnixException.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixException.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2009, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -97,8 +97,8 @@ + } + + void rethrowAsIOException(UnixPath file, UnixPath other) throws IOException { +- String a = (file == null) ? null : file.getPathForExceptionMessage(); +- String b = (other == null) ? null : other.getPathForExceptionMessage(); ++ String a = (file == null) ? null : file.getPathForExecptionMessage(); ++ String b = (other == null) ? null : other.getPathForExecptionMessage(); + IOException x = translateToIOException(a, b); + throw x; + } +@@ -108,6 +108,6 @@ + } + + IOException asIOException(UnixPath file) { +- return translateToIOException(file.getPathForExceptionMessage(), null); ++ return translateToIOException(file.getPathForExecptionMessage(), null); + } + } +--- jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java 2012-08-10 10:31:24.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -238,7 +238,7 @@ + // DirectoryNotEmptyException if not empty + if (attrs != null && attrs.isDirectory() && + (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) +- throw new DirectoryNotEmptyException(file.getPathForExceptionMessage()); ++ throw new DirectoryNotEmptyException(file.getPathForExecptionMessage()); + + x.rethrowAsIOException(file); + return false; +@@ -395,13 +395,13 @@ + + // can't return SecureDirectoryStream on kernels that don't support + // openat, etc. +- if (!supportsAtSysCalls() || !supportsNoFollowLinks()) { ++ if (!supportsAtSysCalls()) { + try { + long ptr = opendir(dir); + return new UnixDirectoryStream(dir, ptr, filter); + } catch (UnixException x) { + if (x.errno() == ENOTDIR) +- throw new NotDirectoryException(dir.getPathForExceptionMessage()); ++ throw new NotDirectoryException(dir.getPathForExecptionMessage()); + x.rethrowAsIOException(dir); + } + } +@@ -421,7 +421,7 @@ + if (dfd2 != -1) + UnixNativeDispatcher.close(dfd2); + if (x.errno() == UnixConstants.ENOTDIR) +- throw new NotDirectoryException(dir.getPathForExceptionMessage()); ++ throw new NotDirectoryException(dir.getPathForExecptionMessage()); + x.rethrowAsIOException(dir); + } + return new UnixSecureDirectoryStream(dir, dp, dfd2, filter); +@@ -490,7 +490,7 @@ + return new UnixPath(link.getFileSystem(), target); + } catch (UnixException x) { + if (x.errno() == UnixConstants.EINVAL) +- throw new NotLinkException(link.getPathForExceptionMessage()); ++ throw new NotLinkException(link.getPathForExecptionMessage()); + x.rethrowAsIOException(link); + return null; // keep compiler happy + } +--- jdk/src/solaris/classes/sun/nio/fs/UnixNativeDispatcher.java 2012-08-10 10:31:25.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixNativeDispatcher.java 2012-08-19 12:40:01.000000000 -0700 +@@ -548,10 +548,6 @@ + return hasAtSysCalls; + } + +- static boolean supportsNoFollowLinks() { +- return UnixConstants.O_NOFOLLOW != 0; +- } +- + // initialize syscalls and fieldIDs + private static native int init(); + +--- jdk/src/solaris/classes/sun/nio/fs/UnixPath.java 2012-08-10 10:31:25.000000000 -0700 ++++ jdk/src/solaris/classes/sun/nio/fs/UnixPath.java 2012-08-19 12:40:01.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -179,7 +179,7 @@ + } + + // use this message when throwing exceptions +- String getPathForExceptionMessage() { ++ String getPathForExecptionMessage() { + return toString(); + } + +@@ -767,11 +767,8 @@ + // package-private + int openForAttributeAccess(boolean followLinks) throws IOException { + int flags = O_RDONLY; +- if (!followLinks) { +- if (!supportsNoFollowLinks()) +- throw new IOException("NOFOLLOW_LINKS is not supported on this platform"); ++ if (!followLinks) + flags |= O_NOFOLLOW; +- } + try { + return open(this, flags, 0); + } catch (UnixException x) { +@@ -780,7 +777,7 @@ + x.setError(ELOOP); + + if (x.errno() == ELOOP) +- throw new FileSystemException(getPathForExceptionMessage(), null, ++ throw new FileSystemException(getPathForExecptionMessage(), null, + x.getMessage() + " or unable to access attributes of symbolic link"); + + x.rethrowAsIOException(this); +--- jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java 2012-08-10 10:31:25.000000000 -0700 ++++ jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java 2012-08-19 12:40:01.000000000 -0700 +@@ -125,6 +125,7 @@ static boolean isBSD() { return (osname.equals("Linux") || @@ -7403,8 +10980,8 @@ osname.contains("OS X")); } ---- jdk/src/solaris/javavm/export/jvm_md.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/javavm/export/jvm_md.h 2012-05-20 10:12:05.000000000 -0700 +--- jdk/src/solaris/javavm/export/jvm_md.h 2012-08-10 10:31:28.000000000 -0700 ++++ jdk/src/solaris/javavm/export/jvm_md.h 2012-08-19 12:40:01.000000000 -0700 @@ -75,7 +75,11 @@ #define JVM_O_O_APPEND O_APPEND #define JVM_O_EXCL O_EXCL @@ -7417,8 +10994,59 @@ /* Signals */ ---- jdk/src/solaris/native/java/io/UnixFileSystem_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/io/UnixFileSystem_md.c 2012-05-17 16:15:00.000000000 -0700 +--- jdk/src/solaris/native/com/sun/management/UnixOperatingSystem_md.c 2012-08-10 10:31:28.000000000 -0700 ++++ jdk/src/solaris/native/com/sun/management/UnixOperatingSystem_md.c 2012-08-19 12:40:01.000000000 -0700 +@@ -168,6 +168,9 @@ + /* + * XXXBSD: there's no way available to get swap info in + * FreeBSD. Usage of libkvm is not an option here ++ * ++ * XXX: Investigate how swapinfo(8) does this. ++ * Total swap is in vm.swap_total + */ + // throw_internal_error(env, "Unimplemented in FreeBSD"); + return (0); +@@ -242,6 +245,8 @@ + #else /* _ALLBSD_SOURCE */ + /* + * XXXBSD: there's no way available to do it in FreeBSD, AFAIK. ++ * ++ * XXX: Determine how linprocfs gets this. + */ + // throw_internal_error(env, "Unimplemented in FreeBSD"); + return (64 * MB); +@@ -323,6 +328,8 @@ + #elif defined(_ALLBSD_SOURCE) + /* + * XXXBSD: there's no way available to do it in FreeBSD, AFAIK. ++ * ++ * XXX: Investigate how top(8) gets this on FreeBSD. + */ + // throw_internal_error(env, "Unimplemented in FreeBSD"); + return (128 * MB); +@@ -342,7 +349,11 @@ + size_t rlen; + + mib[0] = CTL_HW; ++#ifdef __APPLE__ + mib[1] = HW_MEMSIZE; ++#else ++ mib[1] = HW_PHYSMEM; ++#endif + rlen = sizeof(result); + if (sysctl(mib, 2, &result, &rlen, NULL, 0) != 0) { + throw_internal_error(env, "sysctl failed"); +@@ -408,6 +419,8 @@ + #elif defined(_ALLBSD_SOURCE) + /* + * XXXBSD: there's no way available to do it in FreeBSD, AFAIK. ++ * ++ * XXX: Investigate getting this on FreeBSD. Look at lsof. + */ + // throw_internal_error(env, "Unimplemented in FreeBSD"); + return (100); +--- jdk/src/solaris/native/java/io/UnixFileSystem_md.c 2012-08-10 10:31:30.000000000 -0700 ++++ jdk/src/solaris/native/java/io/UnixFileSystem_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -146,7 +146,6 @@ return rv; } @@ -7427,8 +11055,8 @@ JNIEXPORT jboolean JNICALL Java_java_io_UnixFileSystem_setPermission(JNIEnv *env, jobject this, jobject file, ---- jdk/src/solaris/native/java/lang/ProcessEnvironment_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/lang/ProcessEnvironment_md.c 2012-05-17 16:15:00.000000000 -0700 +--- jdk/src/solaris/native/java/lang/ProcessEnvironment_md.c 2012-08-10 10:31:30.000000000 -0700 ++++ jdk/src/solaris/native/java/lang/ProcessEnvironment_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -53,7 +53,7 @@ for (i = 0; environ[i]; i++) { @@ -7447,8 +11075,8 @@ jbyteArray var, val; const char * valBeg = varEnd + 1; jsize varLength = varEnd - environ[i]; ---- jdk/src/solaris/native/java/lang/UNIXProcess_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/lang/UNIXProcess_md.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/java/lang/UNIXProcess_md.c 2012-08-10 10:31:30.000000000 -0700 ++++ jdk/src/solaris/native/java/lang/UNIXProcess_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -394,7 +394,17 @@ return c >= '0' && c <= '9'; } @@ -7476,8 +11104,70 @@ static int moveDescriptor(int fd_from, int fd_to) ---- jdk/src/solaris/native/java/net/NetworkInterface.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/net/NetworkInterface.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/java/net/Inet4AddressImpl.c 2012-08-10 10:31:30.000000000 -0700 ++++ jdk/src/solaris/native/java/net/Inet4AddressImpl.c 2012-08-19 12:40:01.000000000 -0700 +@@ -669,11 +669,11 @@ + sizeof(struct sockaddr)); + if (n < 0 && errno != EINPROGRESS ) { + #ifdef __linux__ +- if (errno != EINVAL && errno != EHOSTUNREACH) ++ if (errno != EINVAL) + /* + * On some Linuxes, when bound to the loopback interface, sendto +- * will fail and errno will be set to EINVAL or EHOSTUNREACH. +- * When that happens, don't throw an exception, just return false. ++ * will fail and errno will be set to EINVAL. When that happens, ++ * don't throw an exception, just return false. + */ + #endif /*__linux__ */ + NET_ThrowNew(env, errno, "Can't send ICMP packet"); +@@ -828,11 +828,10 @@ + case EADDRNOTAVAIL: /* address is not available on the remote machine */ + #ifdef __linux__ + case EINVAL: +- case EHOSTUNREACH: + /* + * On some Linuxes, when bound to the loopback interface, connect +- * will fail and errno will be set to EINVAL or EHOSTUNREACH. +- * When that happens, don't throw an exception, just return false. ++ * will fail and errno will be set to EINVAL. When that happens, ++ * don't throw an exception, just return false. + */ + #endif /* __linux__ */ + close(fd); +--- jdk/src/solaris/native/java/net/Inet6AddressImpl.c 2012-08-10 10:31:30.000000000 -0700 ++++ jdk/src/solaris/native/java/net/Inet6AddressImpl.c 2012-08-19 12:40:01.000000000 -0700 +@@ -512,11 +512,11 @@ + n = sendto(fd, sendbuf, plen, 0, (struct sockaddr*) him, sizeof(struct sockaddr_in6)); + if (n < 0 && errno != EINPROGRESS) { + #ifdef __linux__ +- if (errno != EINVAL && errno != EHOSTUNREACH) ++ if (errno != EINVAL) + /* + * On some Linuxes, when bound to the loopback interface, sendto +- * will fail and errno will be set to EINVAL or EHOSTUNREACH. +- * When that happens, don't throw an exception, just return false. ++ * will fail and errno will be set to EINVAL. When that happens, ++ * don't throw an exception, just return false. + */ + #endif /*__linux__ */ + NET_ThrowNew(env, errno, "Can't send ICMP packet"); +@@ -680,11 +680,10 @@ + case EADDRNOTAVAIL: /* address is not available on the remote machine */ + #ifdef __linux__ + case EINVAL: +- case EHOSTUNREACH: + /* + * On some Linuxes, when bound to the loopback interface, connect +- * will fail and errno will be set to EINVAL or EHOSTUNREACH. +- * When that happens, don't throw an exception, just return false. ++ * will fail and errno will be set to EINVAL. When that happens, ++ * don't throw an exception, just return false. + */ + #endif /* __linux__ */ + close(fd); +--- jdk/src/solaris/native/java/net/NetworkInterface.c 2012-08-10 10:31:31.000000000 -0700 ++++ jdk/src/solaris/native/java/net/NetworkInterface.c 2012-08-19 12:40:01.000000000 -0700 @@ -60,14 +60,18 @@ #include <sys/param.h> #include <sys/ioctl.h> @@ -7499,7 +11189,20 @@ #include "jvm.h" #include "jni_util.h" -@@ -1979,7 +1983,11 @@ +@@ -1289,7 +1293,11 @@ + return -1; + } + +- return if2.ifr_flags; ++#ifdef __FreeBSD__ ++ return ((if2.ifr_flags & 0xffff) | (if2.ifr_flagshigh << 16)); ++#else ++ return (((int) if2.ifr_flags) & 0xffff); ++#endif + } + + #endif +@@ -1979,7 +1987,11 @@ return -1; } @@ -7511,8 +11214,8 @@ } #endif ---- jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c 2012-08-10 10:31:31.000000000 -0700 ++++ jdk/src/solaris/native/java/net/PlainDatagramSocketImpl.c 2012-08-19 12:40:01.000000000 -0700 @@ -23,12 +23,12 @@ * questions. */ @@ -7550,8 +11253,8 @@ len = sizeof(struct sockaddr_in); } JVM_Connect(fd, (struct sockaddr *)&addr, len); ---- jdk/src/solaris/native/java/net/net_util_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/net/net_util_md.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/java/net/net_util_md.c 2012-08-10 10:31:31.000000000 -0700 ++++ jdk/src/solaris/native/java/net/net_util_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -45,6 +45,10 @@ #endif #endif @@ -7563,7 +11266,7 @@ #ifdef __solaris__ #include <sys/sockio.h> #include <stropts.h> -@@ -1485,7 +1489,22 @@ +@@ -1505,7 +1509,22 @@ } } @@ -7587,8 +11290,8 @@ return setsockopt(fd, level, opt, arg, len); } ---- jdk/src/solaris/native/java/net/net_util_md.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/net/net_util_md.h 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/java/net/net_util_md.h 2012-08-10 10:31:31.000000000 -0700 ++++ jdk/src/solaris/native/java/net/net_util_md.h 2012-08-19 12:40:01.000000000 -0700 @@ -37,7 +37,7 @@ #endif @@ -7598,8 +11301,8 @@ extern int NET_Timeout(int s, long timeout); extern int NET_Read(int s, void* buf, size_t len); extern int NET_RecvFrom(int s, void *buf, int len, unsigned int flags, ---- jdk/src/solaris/native/java/util/TimeZone_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/java/util/TimeZone_md.c 2012-05-25 18:05:24.000000000 -0700 +--- jdk/src/solaris/native/java/util/TimeZone_md.c 2012-08-10 10:31:31.000000000 -0700 ++++ jdk/src/solaris/native/java/util/TimeZone_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -123,7 +123,7 @@ return NULL; } @@ -7618,7 +11321,7 @@ /* * Performs Linux specific mapping and returns a zone ID -@@ -672,7 +672,7 @@ +@@ -678,7 +678,7 @@ * Returns a GMT-offset-based zone ID. (e.g., "GMT-08:00") */ @@ -7627,14 +11330,14 @@ char * getGMTOffsetID() -@@ -732,4 +732,4 @@ +@@ -738,4 +738,4 @@ sign, (int)(offset/3600), (int)((offset%3600)/60)); return strdup(buf); } -#endif /* MACOSX */ +#endif /* _ALLBSD_SOURCE */ ---- jdk/src/solaris/native/sun/awt/awt_Font.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_Font.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_Font.c 2012-08-10 10:31:32.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_Font.c 2012-08-19 12:40:01.000000000 -0700 @@ -334,7 +334,7 @@ if (strcmp(style, "regular") == 0) { altstyle = "roman"; @@ -7644,8 +11347,8 @@ if (!strcmp(family, "lucidasans")) { family = "lucida"; } ---- jdk/src/solaris/native/sun/awt/awt_GraphicsEnv.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_GraphicsEnv.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_GraphicsEnv.c 2012-08-10 10:31:32.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_GraphicsEnv.c 2012-08-19 12:40:01.000000000 -0700 @@ -123,7 +123,7 @@ */ @@ -7705,8 +11408,8 @@ #endif /* HEADLESS */ return point; } ---- jdk/src/solaris/native/sun/awt/awt_InputMethod.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_InputMethod.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_InputMethod.c 2012-08-10 10:31:32.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_InputMethod.c 2012-08-19 12:40:01.000000000 -0700 @@ -67,7 +67,7 @@ XIMPreeditDrawCallbackStruct *); static void PreeditCaretCallback(XIC, XPointer, @@ -7946,8 +11649,8 @@ AWT_LOCK(); adjustStatusWindow(window); AWT_UNLOCK(); ---- jdk/src/solaris/native/sun/awt/awt_Robot.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_Robot.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_Robot.c 2012-08-10 10:31:32.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_Robot.c 2012-08-19 12:40:01.000000000 -0700 @@ -45,7 +45,7 @@ #include "wsutils.h" #include "list.h" @@ -7957,8 +11660,8 @@ #include <sys/socket.h> #endif ---- jdk/src/solaris/native/sun/awt/awt_util.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_util.h 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_util.h 2012-08-10 10:31:33.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_util.h 2012-08-19 12:40:01.000000000 -0700 @@ -187,7 +187,7 @@ #ifdef __solaris__ extern Widget awt_util_getXICStatusAreaWindow(Widget w); @@ -7977,8 +11680,8 @@ typedef struct _XmImRefRec { Cardinal num_refs; /* Number of referencing widgets. */ Cardinal max_refs; /* Maximum length of refs array. */ ---- jdk/src/solaris/native/sun/awt/awt_wm.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_wm.c 2011-04-22 23:08:39.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_wm.c 2012-08-10 10:31:33.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_wm.c 2012-08-19 12:40:01.000000000 -0700 @@ -121,12 +121,19 @@ static Atom XA_KWM_WIN_MAXIMIZED; @@ -8076,8 +11779,8 @@ awt_wmgr = OPENLOOK_WM; } else { ---- jdk/src/solaris/native/sun/awt/awt_wm.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/awt_wm.h 2011-04-22 23:08:39.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/awt_wm.h 2012-08-10 10:31:33.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/awt_wm.h 2012-08-19 12:40:01.000000000 -0700 @@ -45,7 +45,10 @@ KDE2_WM, SAWFISH_WM, @@ -8090,8 +11793,8 @@ }; extern void awt_wm_init(void); ---- jdk/src/solaris/native/sun/awt/extutil.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/extutil.h 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/extutil.h 2012-08-10 10:31:33.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/extutil.h 2012-08-19 12:40:01.000000000 -0700 @@ -58,7 +58,7 @@ */ /* $XFree86: xc/include/extensions/extutil.h,v 1.5 2001/01/17 17:53:20 dawes Exp $ */ @@ -8107,8 +11810,8 @@ -#endif /* __linux__ || MACOSX */ +#endif /* __linux__ || _ALLBSD_SOURCE */ ---- jdk/src/solaris/native/sun/awt/fontpath.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/fontpath.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/fontpath.c 2012-08-10 10:31:33.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/fontpath.c 2012-08-19 12:40:01.000000000 -0700 @@ -23,7 +23,7 @@ * questions. */ @@ -8186,8 +11889,8 @@ } #endif #endif /* !HEADLESS */ ---- jdk/src/solaris/native/sun/awt/robot_common.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/awt/robot_common.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/robot_common.c 2012-08-10 10:31:35.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/robot_common.c 2012-08-19 12:40:01.000000000 -0700 @@ -27,7 +27,7 @@ #error This file should not be included in headless library #endif @@ -8197,8 +11900,19 @@ #include <stdlib.h> #endif ---- jdk/src/solaris/native/sun/java2d/j2d_md.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/java2d/j2d_md.h 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/awt/splashscreen/splashscreen_config.h 2012-08-10 10:31:35.000000000 -0700 ++++ jdk/src/solaris/native/sun/awt/splashscreen/splashscreen_config.h 2012-08-19 12:40:01.000000000 -0700 +@@ -32,7 +32,7 @@ + #include <X11/Xutil.h> + #include <X11/extensions/shape.h> + #include <sys/types.h> +-#include <unistd.h> ++#include <sys/unistd.h> + #include <pthread.h> + #include <signal.h> + #include <inttypes.h> +--- jdk/src/solaris/native/sun/java2d/j2d_md.h 2012-08-10 10:31:35.000000000 -0700 ++++ jdk/src/solaris/native/sun/java2d/j2d_md.h 2012-08-19 12:40:01.000000000 -0700 @@ -28,9 +28,9 @@ #include <sys/types.h> @@ -8211,8 +11925,8 @@ #include <stdint.h> #endif /* __linux__ || MACOSX */ ---- jdk/src/solaris/native/sun/java2d/loops/vis_FuncArray.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/java2d/loops/vis_FuncArray.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/java2d/loops/vis_FuncArray.c 2012-08-10 10:31:36.000000000 -0700 ++++ jdk/src/solaris/native/sun/java2d/loops/vis_FuncArray.c 2012-08-19 12:40:01.000000000 -0700 @@ -804,7 +804,7 @@ static int initialized; static int usevis = JNI_TRUE; @@ -8222,8 +11936,94 @@ # define ULTRA_CHIP "sparc64" #else # define ULTRA_CHIP "sun4u" ---- jdk/src/solaris/native/sun/nio/ch/FileChannelImpl.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/nio/ch/FileChannelImpl.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/nio/ch/DatagramChannelImpl.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/DatagramChannelImpl.c 2012-08-19 12:40:01.000000000 -0700 +@@ -77,7 +77,7 @@ + + JNIEXPORT void JNICALL + Java_sun_nio_ch_DatagramChannelImpl_disconnect0(JNIEnv *env, jobject this, +- jobject fdo, jboolean isIPv6) ++ jobject fdo) + { + jint fd = fdval(env, fdo); + int rv; +@@ -94,7 +94,7 @@ + memset(&sa, 0, sizeof(sa)); + + #ifdef AF_INET6 +- if (isIPv6) { ++ if (ipv6_available()) { + struct sockaddr_in6 *him6 = (struct sockaddr_in6 *)&sa; + #if defined(_ALLBSD_SOURCE) + him6->sin6_family = AF_INET6; +--- jdk/src/solaris/native/sun/nio/ch/DatagramDispatcher.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/DatagramDispatcher.c 2012-08-19 12:40:01.000000000 -0700 +@@ -36,7 +36,6 @@ + #include <sys/socket.h> + + #include "nio_util.h" +-#include <limits.h> + + JNIEXPORT jint JNICALL + Java_sun_nio_ch_DatagramDispatcher_read0(JNIEnv *env, jclass clazz, +@@ -61,14 +60,23 @@ + ssize_t result = 0; + struct iovec *iov = (struct iovec *)jlong_to_ptr(address); + struct msghdr m; +- if (len > IOV_MAX) { +- len = IOV_MAX; ++ if (len > 16) { ++ len = 16; + } + +- // initialize the message +- memset(&m, 0, sizeof(m)); ++ m.msg_name = NULL; ++ m.msg_namelen = 0; + m.msg_iov = iov; + m.msg_iovlen = len; ++#ifdef __solaris__ ++ m.msg_accrights = NULL; ++ m.msg_accrightslen = 0; ++#endif ++ ++#if defined(__linux__) || defined(_ALLBSD_SOURCE) ++ m.msg_control = NULL; ++ m.msg_controllen = 0; ++#endif + + result = recvmsg(fd, &m, 0); + if (result < 0 && errno == ECONNREFUSED) { +@@ -100,14 +108,23 @@ + struct iovec *iov = (struct iovec *)jlong_to_ptr(address); + struct msghdr m; + ssize_t result = 0; +- if (len > IOV_MAX) { +- len = IOV_MAX; ++ if (len > 16) { ++ len = 16; + } + +- // initialize the message +- memset(&m, 0, sizeof(m)); ++ m.msg_name = NULL; ++ m.msg_namelen = 0; + m.msg_iov = iov; + m.msg_iovlen = len; ++#ifdef __solaris__ ++ m.msg_accrights = NULL; ++ m.msg_accrightslen = 0; ++#endif ++ ++#if defined(__linux__) || defined(_ALLBSD_SOURCE) ++ m.msg_control = NULL; ++ m.msg_controllen = 0; ++#endif + + result = sendmsg(fd, &m, 0); + if (result < 0 && errno == ECONNREFUSED) { +--- jdk/src/solaris/native/sun/nio/ch/FileChannelImpl.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/FileChannelImpl.c 2012-08-19 12:40:01.000000000 -0700 @@ -201,7 +201,7 @@ return IOS_THROWN; } @@ -8242,9 +12042,38 @@ #endif if (numBytes > 0) ---- jdk/src/solaris/native/sun/nio/ch/FileDispatcherImpl.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/nio/ch/FileDispatcherImpl.c 2012-05-19 21:08:04.000000000 -0700 -@@ -233,6 +233,21 @@ +--- jdk/src/solaris/native/sun/nio/ch/FileDispatcherImpl.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/FileDispatcherImpl.c 2012-08-19 12:40:01.000000000 -0700 +@@ -94,6 +94,9 @@ + { + jint fd = fdval(env, fdo); + struct iovec *iov = (struct iovec *)jlong_to_ptr(address); ++ if (len > 16) { ++ len = 16; ++ } + return convertLongReturnVal(env, readv(fd, iov, len), JNI_TRUE); + } + +@@ -123,6 +126,9 @@ + { + jint fd = fdval(env, fdo); + struct iovec *iov = (struct iovec *)jlong_to_ptr(address); ++ if (len > 16) { ++ len = 16; ++ } + return convertLongReturnVal(env, writev(fd, iov, len), JNI_FALSE); + } + +@@ -200,7 +206,7 @@ + } + lockResult = fcntl(fd, cmd, &fl); + if (lockResult < 0) { +- if ((cmd == F_SETLK64) && (errno == EAGAIN || errno == EACCES)) ++ if ((cmd == F_SETLK64) && (errno == EAGAIN)) + return sun_nio_ch_FileDispatcherImpl_NO_LOCK; + if (errno == EINTR) + return sun_nio_ch_FileDispatcherImpl_INTERRUPTED; +@@ -227,6 +233,21 @@ fl.l_start = (off64_t)pos; fl.l_type = F_UNLCK; lockResult = fcntl(fd, cmd, &fl); @@ -8266,8 +12095,27 @@ if (lockResult < 0) { JNU_ThrowIOExceptionWithLastError(env, "Release failed"); } ---- jdk/src/solaris/native/sun/nio/ch/Sctp.h 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/nio/ch/Sctp.h 2012-05-19 21:00:43.000000000 -0700 +--- jdk/src/solaris/native/sun/nio/ch/IOUtil.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/IOUtil.c 2012-08-19 12:40:01.000000000 -0700 +@@ -144,16 +144,6 @@ + } + } + +-JNIEXPORT jint JNICALL +-Java_sun_nio_ch_IOUtil_iovMax(JNIEnv *env, jclass this) +-{ +- jlong iov_max = sysconf(_SC_IOV_MAX); +- if (iov_max == -1) +- iov_max = 16; +- return (jint)iov_max; +-} +- +- + /* Declared in nio_util.h for use elsewhere in NIO */ + + jlong +--- jdk/src/solaris/native/sun/nio/ch/Sctp.h 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/Sctp.h 2012-08-19 12:40:01.000000000 -0700 @@ -320,8 +320,20 @@ typedef int sctp_peeloff_func(int sock, sctp_assoc_t id); @@ -8307,8 +12155,8 @@ jboolean loadSocketExtensionFuncs(JNIEnv* env); #endif /* !SUN_NIO_CH_SCTP_H */ ---- jdk/src/solaris/native/sun/nio/ch/SctpNet.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/nio/ch/SctpNet.c 2011-04-22 23:08:39.000000000 -0700 +--- jdk/src/solaris/native/sun/nio/ch/SctpNet.c 2012-08-10 10:31:37.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/ch/SctpNet.c 2012-08-19 12:40:01.000000000 -0700 @@ -58,6 +58,7 @@ */ jboolean loadSocketExtensionFuncs @@ -8325,8 +12173,43 @@ funcsLoaded = JNI_TRUE; return JNI_TRUE; ---- jdk/src/solaris/native/sun/security/pkcs11/j2secmod_md.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/security/pkcs11/j2secmod_md.c 2012-05-17 16:15:01.000000000 -0700 +--- jdk/src/solaris/native/sun/nio/fs/genSolarisConstants.c 2012-08-10 10:31:38.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/fs/genSolarisConstants.c 2012-08-19 12:40:01.000000000 -0700 +@@ -27,7 +27,7 @@ + #include <errno.h> + #include <unistd.h> + #include <sys/acl.h> +-#include <fcntl.h> ++#include <sys/fcntl.h> + #include <sys/stat.h> + + /** +--- jdk/src/solaris/native/sun/nio/fs/genUnixConstants.c 2012-08-10 10:31:38.000000000 -0700 ++++ jdk/src/solaris/native/sun/nio/fs/genUnixConstants.c 2012-08-19 12:40:01.000000000 -0700 +@@ -26,7 +26,7 @@ + #include <stdio.h> + #include <errno.h> + #include <unistd.h> +-#include <fcntl.h> ++#include <sys/fcntl.h> + #include <sys/stat.h> + + /** +@@ -69,12 +69,7 @@ + #else + DEFX(O_DSYNC); + #endif +-#ifdef O_NOFOLLOW + DEFX(O_NOFOLLOW); +-#else +- // not supported (dummy values will not be used at runtime). +- emitX("O_NOFOLLOW", 0x0); +-#endif + + // mode masks + emitX("S_IAMB", +--- jdk/src/solaris/native/sun/security/pkcs11/j2secmod_md.c 2012-08-10 10:31:38.000000000 -0700 ++++ jdk/src/solaris/native/sun/security/pkcs11/j2secmod_md.c 2012-08-19 12:40:01.000000000 -0700 @@ -36,6 +36,11 @@ #include "j2secmod.h" @@ -8361,8 +12244,8 @@ (*env)->ReleaseStringUTFChars(env, jLibName, libName); dprintf2("-handle: %u (0X%X)\n", hModule, hModule); ---- jdk/src/solaris/native/sun/xawt/XWindow.c 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/src/solaris/native/sun/xawt/XWindow.c 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/native/sun/xawt/XWindow.c 2012-08-10 10:31:38.000000000 -0700 ++++ jdk/src/solaris/native/sun/xawt/XWindow.c 2012-08-19 12:40:01.000000000 -0700 @@ -867,7 +867,7 @@ { KeySym originalKeysym = *keysym; @@ -8372,8 +12255,171 @@ /* The following code on Linux will cause the keypad keys * not to echo on JTextField when the NumLock is on. The * keysyms will be 0, because the last parameter 2 is not defined. ---- jdk/test/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/Makefile 2012-05-17 16:18:01.000000000 -0700 +--- jdk/src/solaris/transport/socket/socket_md.c 2012-08-10 10:31:39.000000000 -0700 ++++ jdk/src/solaris/transport/socket/socket_md.c 2012-08-19 12:40:01.000000000 -0700 +@@ -35,7 +35,8 @@ + #include <sys/time.h> + #ifdef __solaris__ + #include <thread.h> +-#else ++#endif ++#if defined(__linux__) || defined(_ALLBSD_SOURCE) + #include <pthread.h> + #include <sys/poll.h> + #endif +@@ -305,7 +306,9 @@ + return r; + } + +-#else ++#endif ++ ++#if defined(__linux__) || defined(_ALLBSD_SOURCE) + int + dbgsysTlsAlloc() { + pthread_key_t key; +--- jdk/src/windows/native/java/net/NetworkInterface.c 2012-08-10 10:31:48.000000000 -0700 ++++ jdk/src/windows/native/java/net/NetworkInterface.c 2012-08-19 12:40:02.000000000 -0700 +@@ -504,7 +504,8 @@ + */ + if (netaddrCount < 0) { + netaddrCount = enumAddresses_win(env, ifs, &netaddrP); +- if (netaddrCount == -1) { ++ if ((*env)->ExceptionOccurred(env)) { ++ free_netaddr(netaddrP); + return NULL; + } + } +--- jdk/src/windows/native/java/net/NetworkInterface_winXP.c 2012-08-10 10:31:48.000000000 -0700 ++++ jdk/src/windows/native/java/net/NetworkInterface_winXP.c 2012-08-19 12:40:02.000000000 -0700 +@@ -194,7 +194,8 @@ + while (curr != NULL) { + netaddr *netaddrP; + ret = enumAddresses_win(env, curr, &netaddrP); +- if (ret == -1) { ++ if ((*env)->ExceptionOccurred(env)) { ++ free_netaddr(netaddrP); + return -1; + } + curr->addrs = netaddrP; +@@ -448,7 +449,8 @@ + */ + if (netaddrCount < 0) { + netaddrCount = enumAddresses_win(env, ifs, &netaddrP); +- if (netaddrCount == -1) { ++ if ((*env)->ExceptionOccurred(env)) { ++ free_netaddr(netaddrP); + return NULL; + } + } +--- jdk/src/windows/native/sun/nio/ch/DatagramChannelImpl.c 2012-08-10 10:31:52.000000000 -0700 ++++ jdk/src/windows/native/sun/nio/ch/DatagramChannelImpl.c 2012-08-19 12:40:02.000000000 -0700 +@@ -108,7 +108,7 @@ + + JNIEXPORT void JNICALL + Java_sun_nio_ch_DatagramChannelImpl_disconnect0(JNIEnv *env, jobject this, +- jobject fdo, jboolean isIPv6) ++ jobject fdo) + { + jint fd = fdval(env, fdo); + int rv = 0; +--- jdk/src/windows/native/sun/nio/ch/IOUtil.c 2012-08-10 10:31:52.000000000 -0700 ++++ jdk/src/windows/native/sun/nio/ch/IOUtil.c 2012-08-19 12:40:02.000000000 -0700 +@@ -41,6 +41,9 @@ + /* field id for jint 'fd' in java.io.FileDescriptor used for socket fds */ + static jfieldID fd_fdID; + ++/* false for 95/98/ME, true for NT/W2K */ ++static jboolean onNT = JNI_FALSE; ++ + JNIEXPORT jboolean JNICALL + Java_sun_security_provider_NativeSeedGenerator_nativeGenerateSeed + (JNIEnv *env, jclass clazz, jbyteArray randArray); +@@ -52,6 +55,13 @@ + JNIEXPORT void JNICALL + Java_sun_nio_ch_IOUtil_initIDs(JNIEnv *env, jclass clazz) + { ++ OSVERSIONINFO ver; ++ ver.dwOSVersionInfoSize = sizeof(ver); ++ GetVersionEx(&ver); ++ if (ver.dwPlatformId == VER_PLATFORM_WIN32_NT) { ++ onNT = JNI_TRUE; ++ } ++ + clazz = (*env)->FindClass(env, "java/io/FileDescriptor"); + fd_fdID = (*env)->GetFieldID(env, clazz, "fd", "I"); + handle_fdID = (*env)->GetFieldID(env, clazz, "handle", "J"); +@@ -70,13 +80,6 @@ + randArray); + } + +-JNIEXPORT jint JNICALL +-Java_sun_nio_ch_IOUtil_iovMax(JNIEnv *env, jclass this) +-{ +- return 16; +-} +- +- + jint + convertReturnVal(JNIEnv *env, jint n, jboolean reading) + { +@@ -202,3 +205,9 @@ + { + return (*env)->GetLongField(env, fdo, handle_fdID); + } ++ ++jboolean ++isNT() ++{ ++ return onNT; ++} +--- jdk/src/windows/native/sun/nio/ch/SocketDispatcher.c 2012-08-10 10:31:52.000000000 -0700 ++++ jdk/src/windows/native/sun/nio/ch/SocketDispatcher.c 2012-08-19 12:40:02.000000000 -0700 +@@ -97,6 +97,10 @@ + return IOS_THROWN; + } + ++ if ((isNT() == JNI_FALSE) && (len > 16)) { ++ len = 16; ++ } ++ + /* copy iovec into WSABUF */ + for(i=0; i<len; i++) { + jint iov_len = iovp[i].iov_len; +@@ -204,6 +208,10 @@ + return IOS_THROWN; + } + ++ if ((isNT() == JNI_FALSE) && (len > 16)) { ++ len = 16; ++ } ++ + /* copy iovec into WSABUF */ + for(i=0; i<len; i++) { + jint iov_len = iovp[i].iov_len; +--- jdk/src/windows/native/sun/nio/ch/nio_util.h 2012-08-10 10:31:52.000000000 -0700 ++++ jdk/src/windows/native/sun/nio/ch/nio_util.h 2012-08-19 12:40:02.000000000 -0700 +@@ -35,6 +35,7 @@ + + jint fdval(JNIEnv *env, jobject fdo); + jlong handleval(JNIEnv *env, jobject fdo); ++jboolean isNT(); + jint convertReturnVal(JNIEnv *env, jint n, jboolean r); + jlong convertLongReturnVal(JNIEnv *env, jlong n, jboolean r); + jboolean purgeOutstandingICMP(JNIEnv *env, jclass clazz, jint fd); +--- jdk/src/windows/native/sun/windows/awt_Component.cpp 2012-08-10 10:31:55.000000000 -0700 ++++ jdk/src/windows/native/sun/windows/awt_Component.cpp 2012-08-19 12:40:02.000000000 -0700 +@@ -558,8 +558,6 @@ + + m_hwnd = hwnd; + +- ::ImmAssociateContext(m_hwnd, NULL); +- + SetDrawState((jint)JAWT_LOCK_SURFACE_CHANGED | + (jint)JAWT_LOCK_BOUNDS_CHANGED | + (jint)JAWT_LOCK_CLIP_CHANGED); +--- jdk/test/Makefile 2012-08-10 10:31:59.000000000 -0700 ++++ jdk/test/Makefile 2012-08-19 12:40:02.000000000 -0700 @@ -79,6 +79,11 @@ endif OS_VERSION := $(shell $(UNAME) -r) @@ -8386,8 +12432,8 @@ ifeq ($(UNAME_S), Darwin) OS_NAME = macosx OS_ARCH := $(shell $(UNAME) -m) ---- jdk/test/com/sun/jdi/ImmutableResourceTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/ImmutableResourceTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/ImmutableResourceTest.sh 2012-08-10 10:32:04.000000000 -0700 ++++ jdk/test/com/sun/jdi/ImmutableResourceTest.sh 2012-08-19 12:40:02.000000000 -0700 @@ -56,7 +56,7 @@ OS=`uname -s` @@ -8397,8 +12443,8 @@ PATHSEP=":" ;; ---- jdk/test/com/sun/jdi/JITDebug.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/JITDebug.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/JITDebug.sh 2012-08-10 10:32:04.000000000 -0700 ++++ jdk/test/com/sun/jdi/JITDebug.sh 2012-08-19 12:40:02.000000000 -0700 @@ -63,7 +63,7 @@ OS=`uname -s` export TRANSPORT_METHOD @@ -8408,8 +12454,8 @@ PATHSEP=":" TRANSPORT_METHOD=dt_socket ;; ---- jdk/test/com/sun/jdi/PrivateTransportTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/PrivateTransportTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/PrivateTransportTest.sh 2012-08-10 10:32:05.000000000 -0700 ++++ jdk/test/com/sun/jdi/PrivateTransportTest.sh 2012-08-19 12:40:02.000000000 -0700 @@ -123,7 +123,7 @@ esac libloc=${jreloc}/lib/${libarch} @@ -8419,8 +12465,8 @@ xx=`find ${jreloc}/lib -name libdt_socket.so` libloc=`dirname ${xx}` ;; ---- jdk/test/com/sun/jdi/ShellScaffold.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/ShellScaffold.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/ShellScaffold.sh 2012-08-10 10:32:06.000000000 -0700 ++++ jdk/test/com/sun/jdi/ShellScaffold.sh 2012-08-19 12:40:02.000000000 -0700 @@ -292,7 +292,7 @@ psCmd=ps jstack=jstack.exe @@ -8430,8 +12476,8 @@ transport=dt_socket address= devnull=/dev/null ---- jdk/test/com/sun/jdi/Solaris32AndSolaris64Test.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/Solaris32AndSolaris64Test.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/Solaris32AndSolaris64Test.sh 2012-08-10 10:32:06.000000000 -0700 ++++ jdk/test/com/sun/jdi/Solaris32AndSolaris64Test.sh 2012-08-19 12:40:02.000000000 -0700 @@ -112,7 +112,7 @@ fi ;; @@ -8441,8 +12487,8 @@ pass "This test always passes on $OS" ;; ---- jdk/test/com/sun/jdi/connect/spi/JdiLoadedByCustomLoader.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/jdi/connect/spi/JdiLoadedByCustomLoader.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/jdi/connect/spi/JdiLoadedByCustomLoader.sh 2012-08-10 10:32:07.000000000 -0700 ++++ jdk/test/com/sun/jdi/connect/spi/JdiLoadedByCustomLoader.sh 2012-08-19 12:40:02.000000000 -0700 @@ -45,7 +45,7 @@ OS=`uname -s` @@ -8452,8 +12498,8 @@ PS=":" ;; Windows* | CYGWIN*) ---- jdk/test/com/sun/management/OperatingSystemMXBean/TestTotalSwap.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/management/OperatingSystemMXBean/TestTotalSwap.sh 2012-05-19 16:20:55.000000000 -0700 +--- jdk/test/com/sun/management/OperatingSystemMXBean/TestTotalSwap.sh 2012-08-10 10:32:09.000000000 -0700 ++++ jdk/test/com/sun/management/OperatingSystemMXBean/TestTotalSwap.sh 2012-08-19 12:40:02.000000000 -0700 @@ -72,6 +72,16 @@ done } @@ -8471,19 +12517,18 @@ # Test GetTotalSwapSpaceSize if we are running on Unix total_swap=0 case `uname -s` in -@@ -83,6 +93,10 @@ +@@ -83,6 +93,9 @@ total_swap=`free -b | grep -i swap | awk '{print $2}'` runOne GetTotalSwapSpaceSize $total_swap ;; + *BSD ) + bsd_swap_size -+ runOne GetTotalSwapSpaceSize $total_swap -+ ;; - * ) - runOne GetTotalSwapSpaceSize "sanity-only" - ;; ---- jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetMaxFileDescriptorCount.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetMaxFileDescriptorCount.sh 2011-04-22 23:08:41.000000000 -0700 ++ runOne GetTotalSwapSpaceSize $total_swap + Darwin ) + # $ sysctl -n vm.swapusage + # total = 8192.00M used = 7471.11M free = 720.89M (encrypted) +--- jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetMaxFileDescriptorCount.sh 2012-08-10 10:32:11.000000000 -0700 ++++ jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetMaxFileDescriptorCount.sh 2012-08-19 12:40:02.000000000 -0700 @@ -48,7 +48,7 @@ # Test GetMaxFileDescriptorCount if we are running on Unix @@ -8493,8 +12538,8 @@ runOne GetMaxFileDescriptorCount ;; * ) ---- jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetOpenFileDescriptorCount.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetOpenFileDescriptorCount.sh 2011-04-22 23:08:41.000000000 -0700 +--- jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetOpenFileDescriptorCount.sh 2012-08-10 10:32:11.000000000 -0700 ++++ jdk/test/com/sun/management/UnixOperatingSystemMXBean/GetOpenFileDescriptorCount.sh 2012-08-19 12:40:02.000000000 -0700 @@ -48,7 +48,7 @@ # Test GetOpenFileDescriptorCount if we are running on Unix @@ -8504,8 +12549,8 @@ runOne GetOpenFileDescriptorCount ;; * ) ---- jdk/test/com/sun/tools/attach/CommonSetup.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/com/sun/tools/attach/CommonSetup.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/com/sun/tools/attach/CommonSetup.sh 2012-08-10 10:32:15.000000000 -0700 ++++ jdk/test/com/sun/tools/attach/CommonSetup.sh 2012-08-19 12:40:03.000000000 -0700 @@ -36,7 +36,7 @@ OS=`uname -s` @@ -8515,8 +12560,168 @@ PS=":" FS="/" ;; ---- jdk/test/java/awt/PrintJob/Text/stringwidth.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/awt/PrintJob/Text/stringwidth.sh 2012-05-19 16:22:36.000000000 -0700 +--- jdk/test/java/awt/Focus/OverrideRedirectWindowActivationTest/OverrideRedirectWindowActivationTest.java 2012-08-10 10:32:20.000000000 -0700 ++++ jdk/test/java/awt/Focus/OverrideRedirectWindowActivationTest/OverrideRedirectWindowActivationTest.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,157 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * @test +- * @bug 6385277 +- * @summary Tests that override redirect window gets activated on click. +- * @author anton.tarasov@sun.com: area=awt.focus +- * @library ../../regtesthelpers +- * @build Util +- * @run main OverrideRedirectWindowActivationTest +- */ +-import java.awt.*; +-import java.awt.event.*; +-import java.util.concurrent.Callable; +-import javax.swing.SwingUtilities; +-import sun.awt.SunToolkit; +-import test.java.awt.regtesthelpers.Util; +- +-public class OverrideRedirectWindowActivationTest { +- +- private static Frame frame; +- private static Window window; +- private static Button fbutton; +- private static Button wbutton; +- private static Label label; +- private static Robot robot; +- private static SunToolkit toolkit; +- +- public static void main(String[] args) throws Exception { +- +- if ("sun.awt.motif.MToolkit".equals(Toolkit.getDefaultToolkit().getClass().getName())) { +- System.out.println("No testing on Motif. Test passed."); +- return; +- } +- +- toolkit = (SunToolkit) Toolkit.getDefaultToolkit(); +- robot = new Robot(); +- robot.setAutoDelay(50); +- +- Toolkit.getDefaultToolkit().addAWTEventListener(new AWTEventListener() { +- +- public void eventDispatched(AWTEvent e) { +- System.out.println(e); +- } +- }, FocusEvent.FOCUS_EVENT_MASK | WindowEvent.WINDOW_FOCUS_EVENT_MASK); +- +- createAndShowWindow(); +- toolkit.realSync(); +- +- createAndShowFrame(); +- toolkit.realSync(); +- +- // click on Frame +- clickOn(getClickPoint(frame)); +- +- if (!frame.isFocused()) { +- throw new RuntimeException("Error: a frame couldn't be focused by click."); +- } +- +- //click on Label in Window +- clickOn(getClickPoint(label)); +- +- if (!window.isFocused()) { +- throw new RuntimeException("Test failed: the window couldn't be activated by click!"); +- } +- +- // bring focus back to the frame +- clickOn(getClickPoint(fbutton)); +- +- if (!frame.isFocused()) { +- throw new RuntimeException("Error: a frame couldn't be focused by click."); +- } +- +- // Test 2. Verifies that clicking on a component of unfocusable Window +- // won't activate it. +- +- window.setFocusableWindowState(false); +- toolkit.realSync(); +- +- +- clickOn(getClickPoint(label)); +- +- if (window.isFocused()) { +- throw new RuntimeException("Test failed: unfocusable window got activated by click!"); +- } +- System.out.println("Test passed."); +- +- } +- +- private static void createAndShowWindow() { +- +- frame = new Frame("Test Frame"); +- window = new Window(frame); +- wbutton = new Button("wbutton"); +- label = new Label("label"); +- +- window.setBounds(800, 200, 200, 100); +- window.setLayout(new FlowLayout()); +- window.add(wbutton); +- window.add(label); +- window.setVisible(true); +- +- } +- +- private static void createAndShowFrame() { +- fbutton = new Button("fbutton"); +- +- frame.setBounds(800, 0, 200, 100); +- frame.setLayout(new FlowLayout()); +- frame.add(fbutton); +- frame.setVisible(true); +- +- } +- +- static void clickOn(Point point) { +- +- robot.mouseMove(point.x, point.y); +- +- robot.mousePress(InputEvent.BUTTON1_MASK); +- robot.mouseRelease(InputEvent.BUTTON1_MASK); +- +- toolkit.realSync(); +- } +- +- static Point getClickPoint(Component c) { +- Point p = c.getLocationOnScreen(); +- Dimension d = c.getSize(); +- return new Point(p.x + (int) (d.getWidth() / 2), p.y + (int) (d.getHeight() / 2)); +- } +- +- static Point getClickPoint(Frame frame) { +- Point p = frame.getLocationOnScreen(); +- Dimension d = frame.getSize(); +- return new Point(p.x + (int) (d.getWidth() / 2), p.y + (frame.getInsets().top / 2)); +- } +-} +--- jdk/test/java/awt/PrintJob/Text/stringwidth.sh 2012-08-10 10:32:25.000000000 -0700 ++++ jdk/test/java/awt/PrintJob/Text/stringwidth.sh 2012-08-19 12:40:03.000000000 -0700 @@ -25,10 +25,11 @@ fi @@ -8533,8 +12738,322 @@ # Windows if [ -z "${TESTJAVA}" ] ; then ---- jdk/test/java/io/File/GetXSpace.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/io/File/GetXSpace.sh 2011-04-22 23:08:43.000000000 -0700 +--- jdk/test/java/awt/Window/Grab/GrabTest.java 2012-08-10 10:32:26.000000000 -0700 ++++ jdk/test/java/awt/Window/Grab/GrabTest.java 2012-08-19 12:40:03.000000000 -0700 +@@ -65,7 +65,7 @@ + }, sun.awt.SunToolkit.GRAB_EVENT_MASK); + + f = new Frame("Frame"); +- f.setBounds(0, 0, 300, 300); ++ f.setSize(200, 200); + f.addMouseListener(new MouseAdapter() { + public void mousePressed(MouseEvent e) { + System.out.println(e); +@@ -74,7 +74,7 @@ + }); + + f1 = new Frame("OtherFrame"); +- f1.setBounds(700, 100, 200, 200); ++ f1.setBounds(600, 100, 200, 200); + + w = new Window(f); + w.setLayout(new FlowLayout()); +@@ -86,7 +86,7 @@ + } + }); + w.add(b); +- w.setBounds(400, 100, 200, 200); ++ w.setBounds(300, 100, 200, 200); + w.setBackground(Color.blue); + w.addMouseListener(new MouseAdapter() { + public void mousePressed(MouseEvent e) { +@@ -175,8 +175,7 @@ + + // 6. Check that press on the outside area causes ungrab + Point loc = f.getLocationOnScreen(); +- robot.mouseMove(loc.x + 100, loc.y + f.getSize().height + 1); +- Util.waitForIdle(robot); ++ robot.mouseMove(loc.x + 100, loc.y + f.getSize().height + 300); + robot.mousePress(InputEvent.BUTTON1_MASK); + robot.delay(50); + robot.mouseRelease(InputEvent.BUTTON1_MASK); +--- jdk/test/java/awt/event/TextEvent/TextEventSequenceTest/TextEventSequenceTest.java 2012-08-10 10:32:28.000000000 -0700 ++++ jdk/test/java/awt/event/TextEvent/TextEventSequenceTest/TextEventSequenceTest.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,138 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * @test +- * @bug 4028580 +- * @summary TextArea does not send TextEvent when setText. Does for insert +- * @author kdm@sparc.spb.su: area= awt.TextAvent +- * @run main TextEventSequenceTest +- */ +-import java.awt.*; +-import java.awt.event.*; +-import sun.awt.SunToolkit; +- +-public class TextEventSequenceTest { +- +- private static Frame f; +- private static TextField tf; +- private static TextArea t; +- private static int cntEmptyStrings = 0; +- private static int cntNonEmptyStrings = 0; +- +- public static void main(String[] args) { +- +- test("non-empty text string"); +- test(""); +- test(null); +- } +- +- private static void test(String test) { +- SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit(); +- +- createAndShowGUI(test); +- toolkit.realSync(); +- +- initCounts(); +- t.setText("Hello "); +- toolkit.realSync(); +- t.append("World! !"); +- toolkit.realSync(); +- t.insert("from Roger Pham", 13); +- toolkit.realSync(); +- t.replaceRange("Java Duke", 18, 28); +- toolkit.realSync(); +- checkCounts(0, 4); +- +- initCounts(); +- t.setText(""); +- toolkit.realSync(); +- t.setText(""); +- toolkit.realSync(); +- t.setText(""); +- toolkit.realSync(); +- checkCounts(1, 0); +- +- initCounts(); +- tf.setText("Hello There!"); +- toolkit.realSync(); +- checkCounts(0, 1); +- +- initCounts(); +- tf.setText(""); +- toolkit.realSync(); +- tf.setText(""); +- toolkit.realSync(); +- tf.setText(""); +- toolkit.realSync(); +- checkCounts(1, 0); +- +- f.dispose(); +- } +- +- private static void createAndShowGUI(String text) { +- f = new Frame("TextEventSequenceTest"); +- f.setLayout(new FlowLayout()); +- +- TextListener listener = new MyTextListener(); +- +- tf = new TextField(text); +- tf.addTextListener(listener); +- f.add(tf); +- +- t = new TextArea(text, 10, 30); +- t.addTextListener(listener); +- f.add(t); +- +- f.pack(); +- f.setVisible(true); +- } +- +- static class MyTextListener implements TextListener { +- +- public synchronized void textValueChanged(TextEvent e) { +- TextComponent tc = (TextComponent) e.getSource(); +- String text = tc.getText(); +- if (text.length() == 0) { +- cntEmptyStrings++; +- } else { +- cntNonEmptyStrings++; +- } +- } +- } +- +- synchronized static void initCounts() { +- cntEmptyStrings = 0; +- cntNonEmptyStrings = 0; +- } +- +- synchronized static void checkCounts(int empty, int nonempty) { +- if (empty != cntEmptyStrings || nonempty != cntNonEmptyStrings) { +- throw new RuntimeException( +- String.format("Expected events: empty = %d, nonempty = %d, " +- + "actual events: empty = %d, nonempty = %d", +- empty, nonempty, cntEmptyStrings, cntNonEmptyStrings)); +- } +- } +-} +- +--- jdk/test/java/beans/Performance/Test7122740.java 2012-08-10 10:32:32.000000000 -0700 ++++ jdk/test/java/beans/Performance/Test7122740.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,57 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * @test +- * @bug 7122740 +- * @summary Tests just a benchmark of PropertyDescriptor(String, Class) performance +- * @author Sergey Malenkov +- * @run main/manual Test7122740 +- */ +- +-import java.beans.PropertyDescriptor; +- +-public class Test7122740 { +- public static void main(String[] args) throws Exception { +- long time = System.nanoTime(); +- for (int i = 0; i < 1000; i++) { +- new PropertyDescriptor("name", PropertyDescriptor.class); +- new PropertyDescriptor("value", Concrete.class); +- } +- time -= System.nanoTime(); +- System.out.println("Time (ms): " + (-time / 1000000)); +- } +- +- public static class Abstract<T> { +- private T value; +- public T getValue() { +- return this.value; +- } +- public void setValue(T value) { +- this.value = value; +- } +- } +- +- private static class Concrete extends Abstract<String> { +- } +-} +--- jdk/test/java/beans/Performance/Test7184799.java 2012-08-10 10:32:32.000000000 -0700 ++++ jdk/test/java/beans/Performance/Test7184799.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,71 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * @test +- * @bug 7184799 +- * @summary Tests just a benchmark of Introspector.getBeanInfo(Class) performance +- * @author Sergey Malenkov +- * @run main/manual Test7184799 +- */ +- +-import java.beans.Introspector; +-import java.util.*; +-import java.util.concurrent.ConcurrentHashMap; +- +-public class Test7184799 { +- private static final Class[] TYPES = { +- Class.class, +- String.class, +- Character.class, +- Boolean.class, +- Byte.class, +- Short.class, +- Integer.class, +- Long.class, +- Float.class, +- Double.class, +- Collection.class, +- Set.class, +- HashSet.class, +- TreeSet.class, +- LinkedHashSet.class, +- Map.class, +- HashMap.class, +- TreeMap.class, +- LinkedHashMap.class, +- WeakHashMap.class, +- ConcurrentHashMap.class, +- Dictionary.class, +- Exception.class, +- }; +- +- public static void main(String[] args) throws Exception { +- long time = System.nanoTime(); +- for (Class type : TYPES) { +- Introspector.getBeanInfo(type); +- } +- time -= System.nanoTime(); +- System.out.println("Time (ms): " + (-time / 1000000)); +- } +-} +--- jdk/test/java/io/File/GetXSpace.sh 2012-08-10 10:32:44.000000000 -0700 ++++ jdk/test/java/io/File/GetXSpace.sh 2012-08-19 12:40:04.000000000 -0700 @@ -26,7 +26,7 @@ # set platform-dependent variable OS=`uname -s` @@ -8544,8 +13063,8 @@ Windows_98 ) return ;; Windows* ) SID=`sid`; TMP="c:/temp" ;; * ) ---- jdk/test/java/io/FileOutputStream/ManyFiles.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/io/FileOutputStream/ManyFiles.java 2012-05-19 16:24:37.000000000 -0700 +--- jdk/test/java/io/FileOutputStream/ManyFiles.java 2012-08-10 10:32:46.000000000 -0700 ++++ jdk/test/java/io/FileOutputStream/ManyFiles.java 2012-08-19 12:40:04.000000000 -0700 @@ -43,7 +43,7 @@ // Windows capability it is much simpler to only run it // on that platform. @@ -8555,8 +13074,8 @@ return; for (int n = 0; n < NUM_FILES; n++) { ---- jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh 2012-08-10 10:33:10.000000000 -0700 ++++ jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh 2012-08-19 12:40:04.000000000 -0700 @@ -41,7 +41,7 @@ # Need to determine the classpath separator and filepath separator based on the # operating system. @@ -8566,8 +13085,8 @@ PS=":" ;; Windows* | CYGWIN* ) PS=";" ;; ---- jdk/test/java/io/Serializable/serialver/classpath/run.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/io/Serializable/serialver/classpath/run.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/io/Serializable/serialver/classpath/run.sh 2012-08-10 10:33:31.000000000 -0700 ++++ jdk/test/java/io/Serializable/serialver/classpath/run.sh 2012-08-19 12:40:04.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -8577,8 +13096,8 @@ PS=":" ;; Windows* | CYGWIN* ) PS=";" ;; ---- jdk/test/java/io/Serializable/serialver/nested/run.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/io/Serializable/serialver/nested/run.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/io/Serializable/serialver/nested/run.sh 2012-08-10 10:33:31.000000000 -0700 ++++ jdk/test/java/io/Serializable/serialver/nested/run.sh 2012-08-19 12:40:04.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -8588,8 +13107,8 @@ PS=":" ;; Windows* | CYGWIN* ) PS=";" ;; ---- jdk/test/java/lang/ClassLoader/deadlock/TestCrossDelegate.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/ClassLoader/deadlock/TestCrossDelegate.sh 2012-05-19 16:25:13.000000000 -0700 +--- jdk/test/java/lang/ClassLoader/deadlock/TestCrossDelegate.sh 2012-08-10 10:34:02.000000000 -0700 ++++ jdk/test/java/lang/ClassLoader/deadlock/TestCrossDelegate.sh 2012-08-19 12:40:04.000000000 -0700 @@ -45,13 +45,7 @@ # set platform-specific variables OS=`uname -s` @@ -8605,8 +13124,8 @@ FS="/" ;; Windows*) ---- jdk/test/java/lang/ClassLoader/deadlock/TestOneWayDelegate.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/ClassLoader/deadlock/TestOneWayDelegate.sh 2012-05-19 16:25:55.000000000 -0700 +--- jdk/test/java/lang/ClassLoader/deadlock/TestOneWayDelegate.sh 2012-08-10 10:34:02.000000000 -0700 ++++ jdk/test/java/lang/ClassLoader/deadlock/TestOneWayDelegate.sh 2012-08-19 12:40:04.000000000 -0700 @@ -49,13 +49,7 @@ # set platform-specific variables OS=`uname -s` @@ -8622,8 +13141,8 @@ FS="/" ;; Windows* | CYGWIN* ) ---- jdk/test/java/lang/StringCoding/CheckEncodings.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/StringCoding/CheckEncodings.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/lang/StringCoding/CheckEncodings.sh 2012-08-10 10:34:06.000000000 -0700 ++++ jdk/test/java/lang/StringCoding/CheckEncodings.sh 2012-08-19 12:40:04.000000000 -0700 @@ -30,7 +30,7 @@ # set platform-dependent variables OS=`uname -s` @@ -8633,8 +13152,8 @@ Windows* | CYGWIN* ) echo "Passed"; exit 0 ;; * ) echo "Unrecognized system!" ; exit 1 ;; ---- jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2012-08-10 10:34:07.000000000 -0700 ++++ jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2012-08-19 12:40:04.000000000 -0700 @@ -44,7 +44,7 @@ # set platform-dependent variables OS=`uname -s` @@ -8644,8 +13163,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/java/lang/instrument/MakeJAR2.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/instrument/MakeJAR2.sh 2011-04-22 23:08:45.000000000 -0700 +--- jdk/test/java/lang/instrument/MakeJAR2.sh 2012-08-10 10:34:08.000000000 -0700 ++++ jdk/test/java/lang/instrument/MakeJAR2.sh 2012-08-19 12:40:04.000000000 -0700 @@ -49,7 +49,7 @@ OS=`uname -s` @@ -8655,8 +13174,8 @@ PATHSEP=":" ;; ---- jdk/test/java/lang/instrument/appendToClassLoaderSearch/CommonSetup.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/instrument/appendToClassLoaderSearch/CommonSetup.sh 2012-05-19 16:26:36.000000000 -0700 +--- jdk/test/java/lang/instrument/appendToClassLoaderSearch/CommonSetup.sh 2012-08-10 10:34:11.000000000 -0700 ++++ jdk/test/java/lang/instrument/appendToClassLoaderSearch/CommonSetup.sh 2012-08-19 12:40:04.000000000 -0700 @@ -35,15 +35,7 @@ OS=`uname -s` @@ -8674,8 +13193,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/lang/management/OperatingSystemMXBean/TestSystemLoadAvg.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/lang/management/OperatingSystemMXBean/TestSystemLoadAvg.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/lang/management/OperatingSystemMXBean/TestSystemLoadAvg.sh 2012-08-10 10:34:13.000000000 -0700 ++++ jdk/test/java/lang/management/OperatingSystemMXBean/TestSystemLoadAvg.sh 2012-08-19 12:40:05.000000000 -0700 @@ -61,7 +61,7 @@ while true; do echo "Run $i: TestSystemLoadAvg" @@ -8685,8 +13204,8 @@ runOne GetSystemLoadAverage ;; * ) ---- jdk/test/java/net/Authenticator/B4933582.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/Authenticator/B4933582.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/Authenticator/B4933582.sh 2012-08-10 10:34:17.000000000 -0700 ++++ jdk/test/java/net/Authenticator/B4933582.sh 2012-08-19 12:40:05.000000000 -0700 @@ -26,7 +26,7 @@ OS=`uname -s` @@ -8696,8 +13215,91 @@ PS=":" FS="/" ;; ---- jdk/test/java/net/DatagramSocket/SendDatagramToBadAddress.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/DatagramSocket/SendDatagramToBadAddress.java 2012-05-19 21:01:58.000000000 -0700 +--- jdk/test/java/net/CookieHandler/NullUriCookieTest.java 2012-08-10 10:34:18.000000000 -0700 ++++ jdk/test/java/net/CookieHandler/NullUriCookieTest.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,80 +0,0 @@ +-/* +- * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * @test +- * @bug 6953455 +- * @summary CookieStore.add() cannot handle null URI parameter +- */ +- +-import java.net.CookieManager; +-import java.net.CookieStore; +-import java.net.HttpCookie; +-import java.net.URI; +-import java.net.URISyntaxException; +-import java.util.List; +- +-public class NullUriCookieTest { +- static boolean fail = false; +- +- public static void main(String[] args) throws Exception { +- checkCookieNullUri(); +- } +- +- static void checkCookieNullUri() throws Exception { +- //get a cookie store implementation and add a cookie to the store with null URI +- CookieStore cookieStore = (new CookieManager()).getCookieStore(); +- HttpCookie cookie = new HttpCookie("MY_COOKIE", "MY_COOKIE_VALUE"); +- cookie.setDomain("foo.com"); +- cookieStore.add(null, cookie); +- +- //Retrieve added cookie +- URI uri = new URI("http://foo.com"); +- List<HttpCookie> addedCookieList = cookieStore.get(uri); +- +- //Verify CookieStore behaves well +- if (addedCookieList.size() != 1) { +- fail = true; +- } +- checkFail("Abnormal size of cookie jar"); +- +- for (HttpCookie chip : addedCookieList) { +- if (!chip.equals(cookie)) { +- fail = true; +- } +- } +- checkFail("Cookie not retrieved from Cookie Jar"); +- boolean ret = cookieStore.remove(null,cookie); +- if (!ret) { +- fail = true; +- } +- checkFail("Abnormal removal behaviour from Cookie Jar"); +- } +- +- static void checkFail(String exp) { +- if (fail) { +- throw new RuntimeException(exp); +- } +- } +-} +- +--- jdk/test/java/net/DatagramSocket/SendDatagramToBadAddress.java 2012-08-10 10:34:18.000000000 -0700 ++++ jdk/test/java/net/DatagramSocket/SendDatagramToBadAddress.java 2012-08-19 12:40:05.000000000 -0700 @@ -45,6 +45,8 @@ return (true); if (p.getProperty ("os.name").equals ("Linux")) @@ -8707,8 +13309,8 @@ if (p.getProperty ("os.name").startsWith ("Mac OS")) return (true); // Check for specific Solaris version from here ---- jdk/test/java/net/DatagramSocket/SetDatagramSocketImplFactory/ADatagramSocket.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/DatagramSocket/SetDatagramSocketImplFactory/ADatagramSocket.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/DatagramSocket/SetDatagramSocketImplFactory/ADatagramSocket.sh 2012-08-10 10:34:18.000000000 -0700 ++++ jdk/test/java/net/DatagramSocket/SetDatagramSocketImplFactory/ADatagramSocket.sh 2012-08-19 12:40:05.000000000 -0700 @@ -27,11 +27,7 @@ # set platform-dependent variables OS=`uname -s` @@ -8722,8 +13324,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/net/Socket/OldSocketImpl.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/Socket/OldSocketImpl.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/Socket/OldSocketImpl.sh 2012-08-10 10:34:21.000000000 -0700 ++++ jdk/test/java/net/Socket/OldSocketImpl.sh 2012-08-19 12:40:05.000000000 -0700 @@ -28,7 +28,7 @@ OS=`uname -s` @@ -8733,8 +13335,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/net/URL/B5086147.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/URL/B5086147.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/URL/B5086147.sh 2012-08-10 10:34:22.000000000 -0700 ++++ jdk/test/java/net/URL/B5086147.sh 2012-08-19 12:40:05.000000000 -0700 @@ -26,7 +26,7 @@ OS=`uname -s` @@ -8744,8 +13346,8 @@ exit 0 ;; CYGWIN* ) ---- jdk/test/java/net/URL/runconstructor.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/URL/runconstructor.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/URL/runconstructor.sh 2012-08-10 10:34:23.000000000 -0700 ++++ jdk/test/java/net/URL/runconstructor.sh 2012-08-19 12:40:05.000000000 -0700 @@ -27,7 +27,7 @@ # OS=`uname -s` @@ -8755,8 +13357,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/net/URLClassLoader/B5077773.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/URLClassLoader/B5077773.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/URLClassLoader/B5077773.sh 2012-08-10 10:34:23.000000000 -0700 ++++ jdk/test/java/net/URLClassLoader/B5077773.sh 2012-08-19 12:40:05.000000000 -0700 @@ -34,11 +34,7 @@ OS=`uname -s` @@ -8770,8 +13372,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/net/URLClassLoader/sealing/checksealed.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/URLClassLoader/sealing/checksealed.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/URLClassLoader/sealing/checksealed.sh 2012-08-10 10:34:25.000000000 -0700 ++++ jdk/test/java/net/URLClassLoader/sealing/checksealed.sh 2012-08-19 12:40:05.000000000 -0700 @@ -27,11 +27,7 @@ OS=`uname -s` @@ -8785,8 +13387,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/net/URLConnection/6212146/test.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/net/URLConnection/6212146/test.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/net/URLConnection/6212146/test.sh 2012-08-10 10:34:25.000000000 -0700 ++++ jdk/test/java/net/URLConnection/6212146/test.sh 2012-08-19 12:40:05.000000000 -0700 @@ -33,11 +33,7 @@ OS=`uname -s` @@ -8800,8 +13402,88 @@ PS=":" FS="/" ;; ---- jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/Makefile 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/Makefile 2011-04-22 23:08:46.000000000 -0700 +--- jdk/test/java/nio/channels/DatagramChannel/Disconnect.java 2012-08-10 10:34:28.000000000 -0700 ++++ jdk/test/java/nio/channels/DatagramChannel/Disconnect.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,77 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* @test +- * @bug 7132924 +- * @summary Test DatagramChannel.disconnect when DatagramChannel is connected to an IPv4 socket +- * @run main Disconnect +- * @run main/othervm -Djava.net.preferIPv4Stack=true Disconnect +- */ +- +-import java.net.*; +-import java.nio.*; +-import java.nio.channels.*; +-import java.io.IOException; +- +-public class Disconnect { +- public static void main(String[] args) throws IOException { +- // test with default protocol family +- try (DatagramChannel dc = DatagramChannel.open()) { +- test(dc); +- test(dc); +- } +- +- // test with IPv4 only +- try (DatagramChannel dc = DatagramChannel.open(StandardProtocolFamily.INET)) { +- test(dc); +- test(dc); +- } +- } +- +- /** +- * Connect DatagramChannel to a server, write a datagram and disconnect. Invoke +- * a second or subsequent time with the same DatagramChannel instance to check +- * that disconnect works as expected. +- */ +- static void test(DatagramChannel dc) throws IOException { +- try (DatagramChannel server = DatagramChannel.open()) { +- server.bind(new InetSocketAddress(0)); +- +- InetAddress lh = InetAddress.getLocalHost(); +- dc.connect(new InetSocketAddress(lh, server.socket().getLocalPort())); +- +- dc.write(ByteBuffer.wrap("hello".getBytes())); +- +- ByteBuffer bb = ByteBuffer.allocate(100); +- server.receive(bb); +- +- dc.disconnect(); +- +- try { +- dc.write(ByteBuffer.wrap("another message".getBytes())); +- throw new RuntimeException("write should fail, not connected"); +- } catch (NotYetConnectedException expected) { +- } +- } +- } +-} +--- jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/Makefile 2012-08-10 10:34:31.000000000 -0700 ++++ jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/Makefile 2012-08-19 12:40:05.000000000 -0700 @@ -71,6 +71,48 @@ EXTRA_LIBS = -lc endif @@ -8851,8 +13533,8 @@ LIBDIR=lib/$(PLATFORM)-$(ARCH) LAUNCHERLIB=$(LIBDIR)/libLauncher.so ---- jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh 2011-04-22 23:08:46.000000000 -0700 +--- jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh 2012-08-19 12:40:05.000000000 -0700 @@ -33,11 +33,14 @@ # @run shell run_tests.sh @@ -8921,8 +13603,8 @@ LIBDIR=lib/${PLATFORM}-${ARCH} LAUNCHERLIB=${LIBDIR}/libLauncher.so ---- jdk/test/java/nio/charset/Charset/default.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/charset/Charset/default.sh 2011-04-22 23:08:46.000000000 -0700 +--- jdk/test/java/nio/charset/Charset/default.sh 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/charset/Charset/default.sh 2012-08-19 12:40:05.000000000 -0700 @@ -41,10 +41,14 @@ fi @@ -8942,8 +13624,8 @@ JAVA=$TESTJAVA/bin/java ---- jdk/test/java/nio/charset/coders/CheckSJISMappingProp.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/charset/coders/CheckSJISMappingProp.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/nio/charset/coders/CheckSJISMappingProp.sh 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/charset/coders/CheckSJISMappingProp.sh 2012-08-19 12:40:05.000000000 -0700 @@ -34,7 +34,7 @@ OS=`uname -s` @@ -8953,8 +13635,8 @@ # Skip locale test for Windows Windows* ) echo "Passed"; exit 0 ;; ---- jdk/test/java/nio/charset/spi/basic.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/charset/spi/basic.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/nio/charset/spi/basic.sh 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/charset/spi/basic.sh 2012-08-19 12:40:05.000000000 -0700 @@ -70,10 +70,14 @@ L="$1" shift @@ -8983,8 +13665,8 @@ Windows* ) CPS=';' ;; *) echo "Unknown platform: `uname`"; exit 1 ;; esac ---- jdk/test/java/nio/file/FileSystem/Basic.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/file/FileSystem/Basic.java 2012-05-19 21:04:39.000000000 -0700 +--- jdk/test/java/nio/file/FileSystem/Basic.java 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/file/FileSystem/Basic.java 2012-08-19 12:40:05.000000000 -0700 @@ -76,6 +76,8 @@ checkSupported(fs, "posix", "unix", "owner", "acl", "user"); if (os.equals("Linux")) @@ -8994,8 +13676,8 @@ if (os.contains("OS X")) checkSupported(fs, "posix", "unix", "owner"); if (os.equals("Windows")) ---- jdk/test/java/nio/file/Files/CopyAndMove.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/nio/file/Files/CopyAndMove.java 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/nio/file/Files/CopyAndMove.java 2012-08-10 10:34:32.000000000 -0700 ++++ jdk/test/java/nio/file/Files/CopyAndMove.java 2012-08-19 12:40:05.000000000 -0700 @@ -634,7 +634,7 @@ // check POSIX attributes are copied @@ -9014,8 +13696,8 @@ boolean isDirectory = isDirectory(file, NOFOLLOW_LINKS); if (isUnix) { ---- jdk/test/java/rmi/registry/readTest/readTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/rmi/registry/readTest/readTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/rmi/registry/readTest/readTest.sh 2012-08-10 10:34:39.000000000 -0700 ++++ jdk/test/java/rmi/registry/readTest/readTest.sh 2012-08-19 12:40:06.000000000 -0700 @@ -28,7 +28,7 @@ OS=`uname -s` @@ -9025,8 +13707,8 @@ PS=":" FS="/" FILEURL="file:" ---- jdk/test/java/rmi/reliability/launch_reliability.ksh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/rmi/reliability/launch_reliability.ksh 2011-04-22 23:08:47.000000000 -0700 +--- jdk/test/java/rmi/reliability/launch_reliability.ksh 2012-08-10 10:34:42.000000000 -0700 ++++ jdk/test/java/rmi/reliability/launch_reliability.ksh 2012-08-19 12:40:06.000000000 -0700 @@ -84,14 +84,12 @@ @@ -9046,8 +13728,8 @@ export PATH_SEP mainpid=$$ ---- jdk/test/java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh 2012-05-19 21:05:25.000000000 -0700 +--- jdk/test/java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh 2012-08-10 10:34:51.000000000 -0700 ++++ jdk/test/java/security/Security/ClassLoaderDeadlock/ClassLoaderDeadlock.sh 2012-08-19 12:40:06.000000000 -0700 @@ -46,15 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9065,8 +13747,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock.sh 2012-05-19 21:05:48.000000000 -0700 +--- jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock.sh 2012-08-10 10:34:51.000000000 -0700 ++++ jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock.sh 2012-08-19 12:40:06.000000000 -0700 @@ -34,15 +34,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9084,8 +13766,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock2.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock2.sh 2012-05-19 21:06:15.000000000 -0700 +--- jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock2.sh 2012-08-10 10:34:51.000000000 -0700 ++++ jdk/test/java/security/Security/ClassLoaderDeadlock/Deadlock2.sh 2012-08-19 12:40:06.000000000 -0700 @@ -50,15 +50,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9103,8 +13785,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/security/Security/signedfirst/Dyn.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/security/Security/signedfirst/Dyn.sh 2012-05-19 21:06:42.000000000 -0700 +--- jdk/test/java/security/Security/signedfirst/Dyn.sh 2012-08-10 10:34:51.000000000 -0700 ++++ jdk/test/java/security/Security/signedfirst/Dyn.sh 2012-08-19 12:40:06.000000000 -0700 @@ -46,15 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9122,8 +13804,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/security/Security/signedfirst/Static.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/security/Security/signedfirst/Static.sh 2012-05-19 21:07:17.000000000 -0700 +--- jdk/test/java/security/Security/signedfirst/Static.sh 2012-08-10 10:34:51.000000000 -0700 ++++ jdk/test/java/security/Security/signedfirst/Static.sh 2012-08-19 12:40:06.000000000 -0700 @@ -46,15 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9141,8 +13823,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/util/Currency/PropertiesTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/util/Currency/PropertiesTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/util/Currency/PropertiesTest.sh 2012-08-10 10:34:57.000000000 -0700 ++++ jdk/test/java/util/Currency/PropertiesTest.sh 2012-08-19 12:40:06.000000000 -0700 @@ -30,7 +30,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9152,8 +13834,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/util/PluggableLocale/ExecTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/util/PluggableLocale/ExecTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/util/PluggableLocale/ExecTest.sh 2012-08-10 10:35:02.000000000 -0700 ++++ jdk/test/java/util/PluggableLocale/ExecTest.sh 2012-08-19 12:40:06.000000000 -0700 @@ -58,7 +58,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9163,8 +13845,8 @@ PS=":" FS="/" ;; ---- jdk/test/java/util/ResourceBundle/Bug6299235Test.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/util/ResourceBundle/Bug6299235Test.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/util/ResourceBundle/Bug6299235Test.sh 2012-08-10 10:35:04.000000000 -0700 ++++ jdk/test/java/util/ResourceBundle/Bug6299235Test.sh 2012-08-19 12:40:07.000000000 -0700 @@ -31,7 +31,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9174,8 +13856,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/java/util/ResourceBundle/Control/ExpirationTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/util/ResourceBundle/Control/ExpirationTest.sh 2012-05-20 10:01:42.000000000 -0700 +--- jdk/test/java/util/ResourceBundle/Control/ExpirationTest.sh 2012-08-10 10:35:05.000000000 -0700 ++++ jdk/test/java/util/ResourceBundle/Control/ExpirationTest.sh 2012-08-19 12:40:07.000000000 -0700 @@ -72,10 +72,10 @@ Windows* | CYGWIN* ) DEL=";" @@ -9189,8 +13871,8 @@ DEL=":" HAS_S=YES ;; ---- jdk/test/java/util/ServiceLoader/basic.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/java/util/ServiceLoader/basic.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/util/ServiceLoader/basic.sh 2012-08-10 10:35:06.000000000 -0700 ++++ jdk/test/java/util/ServiceLoader/basic.sh 2012-08-19 12:40:07.000000000 -0700 @@ -42,9 +42,7 @@ OS=`uname -s` @@ -9202,8 +13884,72 @@ SEP=':' ;; * ) SEP='\;' ;; ---- jdk/test/javax/crypto/SecretKeyFactory/FailOverTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/javax/crypto/SecretKeyFactory/FailOverTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/java/util/concurrent/BlockingQueue/LastElement.java 2012-08-10 10:35:08.000000000 -0700 ++++ jdk/test/java/util/concurrent/BlockingQueue/LastElement.java 2012-08-19 12:40:07.000000000 -0700 +@@ -1,5 +1,5 @@ + /* +- * Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. ++ * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it +@@ -23,7 +23,7 @@ + + /* + * @test +- * @bug 6215625 7161229 ++ * @bug 6215625 + * @summary Check correct behavior when last element is removed. + * @author Martin Buchholz + */ +@@ -38,7 +38,9 @@ + testQueue(new ArrayBlockingQueue<Integer>(10, true)); + testQueue(new ArrayBlockingQueue<Integer>(10, false)); + testQueue(new LinkedTransferQueue<Integer>()); +- testQueue(new PriorityBlockingQueue<Integer>()); ++ ++ System.out.printf("%nPassed = %d, failed = %d%n%n", passed, failed); ++ if (failed > 0) throw new Exception("Some tests failed"); + } + + void testQueue(BlockingQueue<Integer> q) throws Throwable { +@@ -57,7 +59,6 @@ + try {check(q.take() == three);} + catch (Throwable t) {unexpected(t);} + check(q.isEmpty() && q.size() == 0); +- check(noRetention(q)); + + // iterator().remove() + q.clear(); +@@ -76,26 +77,6 @@ + check(q.isEmpty() && q.size() == 0); + } + +- boolean noRetention(BlockingQueue<?> q) { +- if (q instanceof PriorityBlockingQueue) { +- PriorityBlockingQueue<?> pbq = (PriorityBlockingQueue) q; +- try { +- java.lang.reflect.Field queue = +- PriorityBlockingQueue.class.getDeclaredField("queue"); +- queue.setAccessible(true); +- Object[] a = (Object[]) queue.get(pbq); +- return a[0] == null; +- } +- catch (NoSuchFieldException e) { +- unexpected(e); +- } +- catch (IllegalAccessException e) { +- // ignore - security manager must be installed +- } +- } +- return true; +- } +- + //--------------------- Infrastructure --------------------------- + volatile int passed = 0, failed = 0; + void pass() {passed++;} +--- jdk/test/javax/crypto/SecretKeyFactory/FailOverTest.sh 2012-08-10 10:35:14.000000000 -0700 ++++ jdk/test/javax/crypto/SecretKeyFactory/FailOverTest.sh 2012-08-19 12:40:07.000000000 -0700 @@ -51,7 +51,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9213,8 +13959,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/javax/imageio/stream/StreamCloserLeak/run_test.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/javax/imageio/stream/StreamCloserLeak/run_test.sh 2012-05-20 10:02:13.000000000 -0700 +--- jdk/test/javax/imageio/stream/StreamCloserLeak/run_test.sh 2012-08-10 10:35:15.000000000 -0700 ++++ jdk/test/javax/imageio/stream/StreamCloserLeak/run_test.sh 2012-08-19 12:40:07.000000000 -0700 @@ -84,7 +84,7 @@ TMP="/tmp" ;; @@ -9224,8 +13970,8 @@ VAR="A different value for Linux" DEFAULT_JDK=/usr/local/java/jdk1.4/linux-i386 FILESEP="/" ---- jdk/test/javax/script/CommonSetup.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/javax/script/CommonSetup.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/javax/script/CommonSetup.sh 2012-08-10 10:35:25.000000000 -0700 ++++ jdk/test/javax/script/CommonSetup.sh 2012-08-19 12:40:07.000000000 -0700 @@ -36,7 +36,7 @@ OS=`uname -s` @@ -9235,8 +13981,8 @@ PS=":" FS="/" ;; ---- jdk/test/javax/security/auth/Subject/doAs/Test.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/javax/security/auth/Subject/doAs/Test.sh 2012-05-20 10:02:50.000000000 -0700 +--- jdk/test/javax/security/auth/Subject/doAs/Test.sh 2012-08-10 10:35:26.000000000 -0700 ++++ jdk/test/javax/security/auth/Subject/doAs/Test.sh 2012-08-19 12:40:07.000000000 -0700 @@ -33,17 +33,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9256,8 +14002,234 @@ PS=":" FS="/" RM="/bin/rm -f" ---- jdk/test/jprt.config 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/jprt.config 2011-04-22 23:08:51.000000000 -0700 +--- jdk/test/javax/swing/JComponent/7154030/bug7154030.java 2012-08-10 10:36:00.000000000 -0700 ++++ jdk/test/javax/swing/JComponent/7154030/bug7154030.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,169 +0,0 @@ +-/* +- * Copyright (c) 2012 Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * Portions Copyright (c) 2012 IBM Corporation +- */ +- +-import javax.swing.JButton; +-import javax.swing.JDesktopPane; +-import javax.swing.JFrame; +-import javax.swing.SwingUtilities; +-import sun.awt.SunToolkit; +- +-import java.awt.AWTException; +-import java.awt.AlphaComposite; +-import java.awt.Color; +-import java.awt.Graphics; +-import java.awt.Graphics2D; +-import java.awt.Rectangle; +-import java.awt.Robot; +-import java.awt.Toolkit; +-import java.awt.image.BufferedImage; +- +-/* @test 1.1 2012/04/12 +- * @bug 7154030 +- * @summary Swing components fail to hide after calling hide() +- * @author Jonathan Lu +- * @library ../../regtesthelpers/ +- * @build Util +- * @run main bug7154030 +- */ +- +-public class bug7154030 { +- +- private static JButton button = null; +- +- public static void main(String[] args) throws Exception { +- BufferedImage imageInit = null; +- +- BufferedImage imageShow = null; +- +- BufferedImage imageHide = null; +- +- SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit(); +- +- Robot robot = new Robot(); +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- JDesktopPane desktop = new JDesktopPane(); +- button = new JButton("button"); +- JFrame frame = new JFrame(); +- +- button.setSize(200, 200); +- button.setLocation(100, 100); +- button.setForeground(Color.RED); +- button.setBackground(Color.RED); +- button.setOpaque(true); +- button.setVisible(false); +- desktop.add(button); +- +- frame.setContentPane(desktop); +- frame.setSize(300, 300); +- frame.setLocation(0, 0); +- frame.setVisible(true); +- frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE); +- } +- }); +- +- toolkit.realSync(); +- imageInit = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- button.show(); +- } +- }); +- +- toolkit.realSync(); +- imageShow = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- if (Util.compareBufferedImages(imageInit, imageShow)) { +- throw new Exception("Failed to show opaque button"); +- } +- +- toolkit.realSync(); +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- button.hide(); +- } +- }); +- +- toolkit.realSync(); +- imageHide = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- +- if (!Util.compareBufferedImages(imageInit, imageHide)) { +- throw new Exception("Failed to hide opaque button"); +- } +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- button.setOpaque(false); +- button.setBackground(new Color(128, 128, 0)); +- button.setVisible(false); +- } +- }); +- +- toolkit.realSync(); +- imageInit = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- button.show(); +- } +- }); +- +- toolkit.realSync(); +- imageShow = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- +- SwingUtilities.invokeAndWait(new Runnable() { +- +- @Override +- public void run() { +- button.hide(); +- } +- }); +- +- if (Util.compareBufferedImages(imageInit, imageShow)) { +- throw new Exception("Failed to show non-opaque button"); +- } +- +- toolkit.realSync(); +- imageHide = robot.createScreenCapture(new Rectangle(0, 0, 300, 300)); +- +- if (!Util.compareBufferedImages(imageInit, imageHide)) { +- throw new Exception("Failed to hide non-opaque button"); +- } +- } +-} +--- jdk/test/javax/swing/text/DefaultCaret/6938583/bug6938583.java 2012-08-10 10:36:15.000000000 -0700 ++++ jdk/test/javax/swing/text/DefaultCaret/6938583/bug6938583.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,51 +0,0 @@ +-/* +- * Copyright (c) 2011 Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-/* +- * Portions Copyright (c) 2011 IBM Corporation +- */ +- +-/* +- * @test +- * @bug 6938583 +- * @summary Unexpected NullPointerException when use CodeIM demo on windows +- * @author LittleE +- */ +- +-import javax.swing.*; +-import javax.swing.text.DefaultCaret; +-import java.awt.event.MouseEvent; +- +-public class bug6938583 { +- public static void main(String[] args) throws Exception { +- SwingUtilities.invokeAndWait(new Runnable() { +- public void run() { +- JTextArea jta = new JTextArea(); +- DefaultCaret dc = new DefaultCaret(); +- jta.setCaret(dc); +- dc.deinstall(jta); +- dc.mouseClicked(new MouseEvent(jta, MouseEvent.MOUSE_CLICKED, 0, 0, 0, 0, 0, false)); +- } +- }); +- } +-} +--- jdk/test/jprt.config 2012-08-10 10:36:17.000000000 -0700 ++++ jdk/test/jprt.config 2012-08-19 12:40:08.000000000 -0700 @@ -71,8 +71,8 @@ # Uses 'uname -s', but only expect SunOS or Linux, assume Windows otherwise. @@ -9325,8 +14297,8 @@ # Export PATH setting PATH="${path4sdk}" ---- jdk/test/lib/security/java.policy/Ext_AllPolicy.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/lib/security/java.policy/Ext_AllPolicy.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/lib/security/java.policy/Ext_AllPolicy.sh 2012-08-10 10:36:17.000000000 -0700 ++++ jdk/test/lib/security/java.policy/Ext_AllPolicy.sh 2012-08-19 12:40:08.000000000 -0700 @@ -50,7 +50,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9336,8 +14308,94 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/management/jmxremote/bootstrap/CustomLauncherTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/management/jmxremote/bootstrap/CustomLauncherTest.sh 2012-05-20 10:04:06.000000000 -0700 +--- jdk/test/sun/java2d/OpenGL/bug7181438.java 2012-08-10 10:36:19.000000000 -0700 ++++ jdk/test/sun/java2d/OpenGL/bug7181438.java 1969-12-31 16:00:00.000000000 -0800 +@@ -1,83 +0,0 @@ +-/* +- * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +- * +- * This code is free software; you can redistribute it and/or modify it +- * under the terms of the GNU General Public License version 2 only, as +- * published by the Free Software Foundation. +- * +- * This code is distributed in the hope that it will be useful, but WITHOUT +- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +- * version 2 for more details (a copy is included in the LICENSE file that +- * accompanied this code). +- * +- * You should have received a copy of the GNU General Public License version +- * 2 along with this work; if not, write to the Free Software Foundation, +- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +- * +- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +- * or visit www.oracle.com if you need additional information or have any +- * questions. +- */ +- +-import java.awt.Color; +-import java.awt.Graphics; +-import java.awt.GraphicsConfiguration; +-import java.awt.GraphicsEnvironment; +-import java.awt.Transparency; +-import java.awt.image.BufferedImage; +-import java.awt.image.VolatileImage; +- +-/** +- * @test +- * @bug 7181438 +- * @summary Verifies that we get correct alpha, when we draw opaque +- * BufferedImage to non opaque VolatileImage via intermediate opaque texture. +- * @author Sergey Bylokhov +- * @run main/othervm -Dsun.java2d.accthreshold=0 bug7181438 +- */ +-public final class bug7181438 { +- +- private static final int SIZE = 500; +- +- public static void main(final String[] args) { +- +- final BufferedImage bi = createBufferedImage(); +- final VolatileImage vi = createVolatileImage(); +- final Graphics s2dVi = vi.getGraphics(); +- +- //sw->texture->surface blit +- s2dVi.drawImage(bi, 0, 0, null); +- +- final BufferedImage results = vi.getSnapshot(); +- for (int i = 0; i < SIZE; ++i) { +- for (int j = 0; j < SIZE; ++j) { +- //Image should be opaque: (black color and alpha = 255) +- if (results.getRGB(i, j) != 0xFF000000) { +- throw new RuntimeException("Failed: Wrong alpha"); +- } +- } +- } +- System.out.println("Passed"); +- } +- +- +- private static VolatileImage createVolatileImage() { +- final GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment(); +- final GraphicsConfiguration gc = ge.getDefaultScreenDevice().getDefaultConfiguration(); +- return gc.createCompatibleVolatileImage(SIZE, SIZE, +- Transparency.TRANSLUCENT); +- } +- +- private static BufferedImage createBufferedImage() { +- final BufferedImage bi = new BufferedImage(SIZE, SIZE, +- BufferedImage.TYPE_INT_RGB); +- final Graphics bg = bi.getGraphics(); +- //Black color and alpha = 0 +- bg.setColor(new Color(0, 0, 0, 0)); +- bg.fillRect(0, 0, SIZE, SIZE); +- bg.dispose(); +- return bi; +- } +-} +--- jdk/test/sun/management/jmxremote/bootstrap/CustomLauncherTest.sh 2012-08-10 10:36:21.000000000 -0700 ++++ jdk/test/sun/management/jmxremote/bootstrap/CustomLauncherTest.sh 2012-08-19 12:40:08.000000000 -0700 @@ -45,37 +45,53 @@ # has to locate libjvm.so. Also $! is not reliable on some releases of MKS. #{ @@ -9417,8 +14475,8 @@ # ---- jdk/test/sun/management/jmxremote/bootstrap/GeneratePropertyPassword.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/management/jmxremote/bootstrap/GeneratePropertyPassword.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/management/jmxremote/bootstrap/GeneratePropertyPassword.sh 2012-08-10 10:36:21.000000000 -0700 ++++ jdk/test/sun/management/jmxremote/bootstrap/GeneratePropertyPassword.sh 2012-08-19 12:40:08.000000000 -0700 @@ -35,7 +35,7 @@ UMASK=`umask` @@ -9428,8 +14486,8 @@ PATHSEP=":" FILESEP="/" DFILESEP=$FILESEP ---- jdk/test/sun/management/jmxremote/bootstrap/LocalManagementTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/management/jmxremote/bootstrap/LocalManagementTest.sh 2011-04-22 23:08:51.000000000 -0700 +--- jdk/test/sun/management/jmxremote/bootstrap/LocalManagementTest.sh 2012-08-10 10:36:21.000000000 -0700 ++++ jdk/test/sun/management/jmxremote/bootstrap/LocalManagementTest.sh 2012-08-19 12:40:08.000000000 -0700 @@ -86,10 +86,12 @@ # on Windows 98. @@ -9447,8 +14505,8 @@ JAVA=${TESTJAVA}/bin/java CLASSPATH=${TESTCLASSES} ---- jdk/test/sun/management/jmxremote/bootstrap/PasswordFilePermissionTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/management/jmxremote/bootstrap/PasswordFilePermissionTest.sh 2011-04-22 23:08:51.000000000 -0700 +--- jdk/test/sun/management/jmxremote/bootstrap/PasswordFilePermissionTest.sh 2012-08-10 10:36:21.000000000 -0700 ++++ jdk/test/sun/management/jmxremote/bootstrap/PasswordFilePermissionTest.sh 2012-08-19 12:40:08.000000000 -0700 @@ -70,10 +70,12 @@ # security the password file. @@ -9466,8 +14524,8 @@ # Create configuration file and dummy password file ---- jdk/test/sun/management/jmxremote/bootstrap/SSLConfigFilePermissionTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/management/jmxremote/bootstrap/SSLConfigFilePermissionTest.sh 2011-04-22 23:08:51.000000000 -0700 +--- jdk/test/sun/management/jmxremote/bootstrap/SSLConfigFilePermissionTest.sh 2012-08-10 10:36:22.000000000 -0700 ++++ jdk/test/sun/management/jmxremote/bootstrap/SSLConfigFilePermissionTest.sh 2012-08-19 12:40:08.000000000 -0700 @@ -69,10 +69,12 @@ # security the password file. @@ -9485,8 +14543,8 @@ # Create management and SSL configuration files ---- jdk/test/sun/misc/URLClassPath/ClassnameCharTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/misc/URLClassPath/ClassnameCharTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/misc/URLClassPath/ClassnameCharTest.sh 2012-08-10 10:36:24.000000000 -0700 ++++ jdk/test/sun/misc/URLClassPath/ClassnameCharTest.sh 2012-08-19 12:40:09.000000000 -0700 @@ -36,7 +36,7 @@ OS=`uname -s` @@ -9496,8 +14554,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/net/www/MarkResetTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/net/www/MarkResetTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/net/www/MarkResetTest.sh 2012-08-10 10:36:27.000000000 -0700 ++++ jdk/test/sun/net/www/MarkResetTest.sh 2012-08-19 12:40:09.000000000 -0700 @@ -28,7 +28,7 @@ OS=`uname -s` @@ -9507,8 +14565,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/net/www/http/HttpClient/RetryPost.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/net/www/http/HttpClient/RetryPost.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/net/www/http/HttpClient/RetryPost.sh 2012-08-10 10:36:28.000000000 -0700 ++++ jdk/test/sun/net/www/http/HttpClient/RetryPost.sh 2012-08-19 12:40:09.000000000 -0700 @@ -28,7 +28,7 @@ OS=`uname -s` @@ -9518,8 +14576,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/net/www/protocol/jar/B5105410.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/net/www/protocol/jar/B5105410.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/net/www/protocol/jar/B5105410.sh 2012-08-10 10:36:29.000000000 -0700 ++++ jdk/test/sun/net/www/protocol/jar/B5105410.sh 2012-08-19 12:40:09.000000000 -0700 @@ -31,7 +31,7 @@ OS=`uname -s` @@ -9529,8 +14587,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/net/www/protocol/jar/jarbug/run.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/net/www/protocol/jar/jarbug/run.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/net/www/protocol/jar/jarbug/run.sh 2012-08-10 10:36:30.000000000 -0700 ++++ jdk/test/sun/net/www/protocol/jar/jarbug/run.sh 2012-08-19 12:40:09.000000000 -0700 @@ -31,7 +31,7 @@ OS=`uname -s` @@ -9540,19 +14598,19 @@ PS=":" FS="/" ;; ---- jdk/test/sun/nio/ch/SelProvider.java 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/nio/ch/SelProvider.java 2012-05-19 20:59:15.000000000 -0700 -@@ -50,6 +50,8 @@ - } else { - throw new RuntimeException("Test does not recognize this operating system"); - } +--- jdk/test/sun/nio/ch/SelProvider.java 2012-08-10 10:36:30.000000000 -0700 ++++ jdk/test/sun/nio/ch/SelProvider.java 2012-08-19 12:40:09.000000000 -0700 +@@ -39,6 +39,8 @@ + expected = "sun.nio.ch.DevPollSelectorProvider"; + } else if ("Linux".equals(osname)) { + expected = "sun.nio.ch.EPollSelectorProvider"; + } else if (osname.endsWith("BSD")) { -+ expected = "sun.nio.ch.PollSelectorProvider"; ++ expected = "sun.nio.ch.KQueueSelectorProvider"; } else if (osname.contains("OS X")) { - expected = "sun.nio.ch.PollSelectorProvider"; + expected = "sun.nio.ch.KQueueSelectorProvider"; } else ---- jdk/test/sun/security/krb5/runNameEquals.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/krb5/runNameEquals.sh 2012-05-19 20:58:43.000000000 -0700 +--- jdk/test/sun/security/krb5/runNameEquals.sh 2012-08-10 10:36:39.000000000 -0700 ++++ jdk/test/sun/security/krb5/runNameEquals.sh 2012-08-19 12:40:09.000000000 -0700 @@ -48,15 +48,11 @@ # set platform-dependent variables OS=`uname -s` @@ -9570,8 +14628,8 @@ CYGWIN* ) PATHSEP=";" FILESEP="/" ---- jdk/test/sun/security/pkcs11/KeyStore/Basic.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/pkcs11/KeyStore/Basic.sh 2012-05-19 20:57:48.000000000 -0700 +--- jdk/test/sun/security/pkcs11/KeyStore/Basic.sh 2012-08-10 10:36:40.000000000 -0700 ++++ jdk/test/sun/security/pkcs11/KeyStore/Basic.sh 2012-08-19 12:40:09.000000000 -0700 @@ -131,6 +131,27 @@ ;; esac @@ -9600,8 +14658,8 @@ Windows* ) FS="\\" PS=";" ---- jdk/test/sun/security/pkcs11/KeyStore/ClientAuth.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/pkcs11/KeyStore/ClientAuth.sh 2012-05-19 20:57:18.000000000 -0700 +--- jdk/test/sun/security/pkcs11/KeyStore/ClientAuth.sh 2012-08-10 10:36:41.000000000 -0700 ++++ jdk/test/sun/security/pkcs11/KeyStore/ClientAuth.sh 2012-08-19 12:40:09.000000000 -0700 @@ -93,6 +93,27 @@ ;; esac @@ -9630,8 +14688,8 @@ Windows* ) FS="\\" PS=";" ---- jdk/test/sun/security/pkcs11/Provider/ConfigQuotedString.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/pkcs11/Provider/ConfigQuotedString.sh 2012-05-19 20:56:13.000000000 -0700 +--- jdk/test/sun/security/pkcs11/Provider/ConfigQuotedString.sh 2012-08-10 10:36:42.000000000 -0700 ++++ jdk/test/sun/security/pkcs11/Provider/ConfigQuotedString.sh 2012-08-19 12:40:09.000000000 -0700 @@ -50,19 +50,7 @@ OS=`uname -s` @@ -9653,8 +14711,8 @@ FS="/" PS=":" CP="${FS}bin${FS}cp" ---- jdk/test/sun/security/pkcs11/Provider/Login.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/pkcs11/Provider/Login.sh 2012-05-19 20:55:50.000000000 -0700 +--- jdk/test/sun/security/pkcs11/Provider/Login.sh 2012-08-10 10:36:42.000000000 -0700 ++++ jdk/test/sun/security/pkcs11/Provider/Login.sh 2012-08-19 12:40:09.000000000 -0700 @@ -51,19 +51,7 @@ OS=`uname -s` @@ -9676,8 +14734,8 @@ FS="/" PS=":" CP="${FS}bin${FS}cp" ---- jdk/test/sun/security/provider/PolicyFile/GrantAllPermToExtWhenNoPolicy.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/provider/PolicyFile/GrantAllPermToExtWhenNoPolicy.sh 2011-04-22 23:08:53.000000000 -0700 +--- jdk/test/sun/security/provider/PolicyFile/GrantAllPermToExtWhenNoPolicy.sh 2012-08-10 10:36:53.000000000 -0700 ++++ jdk/test/sun/security/provider/PolicyFile/GrantAllPermToExtWhenNoPolicy.sh 2012-08-19 12:40:10.000000000 -0700 @@ -44,11 +44,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9691,8 +14749,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/sun/security/provider/PolicyFile/getinstance/getinstance.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/provider/PolicyFile/getinstance/getinstance.sh 2012-05-19 20:54:54.000000000 -0700 +--- jdk/test/sun/security/provider/PolicyFile/getinstance/getinstance.sh 2012-08-10 10:36:55.000000000 -0700 ++++ jdk/test/sun/security/provider/PolicyFile/getinstance/getinstance.sh 2012-08-19 12:40:10.000000000 -0700 @@ -47,15 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9710,8 +14768,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/EngineArgs/DebugReportsOneExtraByte.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/EngineArgs/DebugReportsOneExtraByte.sh 2012-05-19 20:54:32.000000000 -0700 +--- jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/EngineArgs/DebugReportsOneExtraByte.sh 2012-08-10 10:36:58.000000000 -0700 ++++ jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/EngineArgs/DebugReportsOneExtraByte.sh 2012-08-19 12:40:10.000000000 -0700 @@ -33,7 +33,7 @@ OS=`uname -s` @@ -9721,8 +14779,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/SSLSocketImpl/NotifyHandshakeTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/SSLSocketImpl/NotifyHandshakeTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/SSLSocketImpl/NotifyHandshakeTest.sh 2012-08-10 10:36:59.000000000 -0700 ++++ jdk/test/sun/security/ssl/com/sun/net/ssl/internal/ssl/SSLSocketImpl/NotifyHandshakeTest.sh 2012-08-19 12:40:10.000000000 -0700 @@ -42,7 +42,7 @@ OS=`uname -s` @@ -9732,8 +14790,8 @@ FILESEP="/" PATHSEP=":" ;; ---- jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.sh 2012-08-10 10:37:02.000000000 -0700 ++++ jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.sh 2012-08-19 12:40:10.000000000 -0700 @@ -32,7 +32,7 @@ HOSTNAME=`uname -n` OS=`uname -s` @@ -9743,8 +14801,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.sh 2012-08-10 10:37:03.000000000 -0700 ++++ jdk/test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.sh 2012-08-19 12:40:10.000000000 -0700 @@ -32,7 +32,7 @@ HOSTNAME=`uname -n` OS=`uname -s` @@ -9754,8 +14812,8 @@ PS=":" FS="/" ;; ---- jdk/test/sun/security/tools/jarsigner/AlgOptions.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/jarsigner/AlgOptions.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/jarsigner/AlgOptions.sh 2012-08-10 10:37:03.000000000 -0700 ++++ jdk/test/sun/security/tools/jarsigner/AlgOptions.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9765,8 +14823,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/jarsigner/PercentSign.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/jarsigner/PercentSign.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/jarsigner/PercentSign.sh 2012-08-10 10:37:03.000000000 -0700 ++++ jdk/test/sun/security/tools/jarsigner/PercentSign.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9776,8 +14834,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/jarsigner/diffend.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/jarsigner/diffend.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/jarsigner/diffend.sh 2012-08-10 10:37:03.000000000 -0700 ++++ jdk/test/sun/security/tools/jarsigner/diffend.sh 2012-08-19 12:40:10.000000000 -0700 @@ -41,7 +41,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9787,8 +14845,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/jarsigner/oldsig.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/jarsigner/oldsig.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/jarsigner/oldsig.sh 2012-08-10 10:37:03.000000000 -0700 ++++ jdk/test/sun/security/tools/jarsigner/oldsig.sh 2012-08-19 12:40:10.000000000 -0700 @@ -42,7 +42,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9798,8 +14856,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/keytool/AltProviderPath.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/AltProviderPath.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/AltProviderPath.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/AltProviderPath.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9809,8 +14867,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/keytool/CloneKeyAskPassword.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/CloneKeyAskPassword.sh 2012-05-19 20:54:02.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/CloneKeyAskPassword.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/CloneKeyAskPassword.sh 2012-08-19 12:40:10.000000000 -0700 @@ -47,15 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9828,8 +14886,8 @@ PATHSEP=":" FILESEP="/" ;; ---- jdk/test/sun/security/tools/keytool/NoExtNPE.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/NoExtNPE.sh 2012-05-19 10:52:58.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/NoExtNPE.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/NoExtNPE.sh 2012-08-19 12:40:10.000000000 -0700 @@ -42,13 +42,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9845,8 +14903,8 @@ FILESEP="/" ;; CYGWIN* ) ---- jdk/test/sun/security/tools/keytool/SecretKeyKS.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/SecretKeyKS.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/SecretKeyKS.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/SecretKeyKS.sh 2012-08-19 12:40:10.000000000 -0700 @@ -45,7 +45,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9856,8 +14914,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/keytool/StandardAlgName.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/StandardAlgName.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/StandardAlgName.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/StandardAlgName.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9867,8 +14925,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/keytool/autotest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/autotest.sh 2011-04-22 23:08:54.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/autotest.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/autotest.sh 2012-08-19 12:40:10.000000000 -0700 @@ -72,6 +72,27 @@ ;; esac @@ -9897,8 +14955,8 @@ * ) echo "Will not run test on: ${OS}" exit 0; ---- jdk/test/sun/security/tools/keytool/i18n.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/i18n.sh 2011-04-22 23:08:54.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/i18n.sh 2012-08-10 10:37:04.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/i18n.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9908,8 +14966,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/keytool/printssl.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/printssl.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/printssl.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/printssl.sh 2012-08-19 12:40:10.000000000 -0700 @@ -37,7 +37,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9919,8 +14977,8 @@ FS="/" ;; CYGWIN* ) ---- jdk/test/sun/security/tools/keytool/resource.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/resource.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/resource.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/resource.sh 2012-08-19 12:40:10.000000000 -0700 @@ -43,7 +43,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9930,8 +14988,8 @@ NULL=/dev/null FS="/" TMP=/tmp ---- jdk/test/sun/security/tools/keytool/standard.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/keytool/standard.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/keytool/standard.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/keytool/standard.sh 2012-08-19 12:40:10.000000000 -0700 @@ -44,7 +44,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9941,8 +14999,8 @@ FS="/" ;; Windows_* ) ---- jdk/test/sun/security/tools/policytool/Alias.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/Alias.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/Alias.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/Alias.sh 2012-08-19 12:40:10.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9952,8 +15010,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/ChangeUI.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/ChangeUI.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/ChangeUI.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/ChangeUI.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9963,8 +15021,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/OpenPolicy.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/OpenPolicy.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/OpenPolicy.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/OpenPolicy.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9974,8 +15032,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/SaveAs.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/SaveAs.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/SaveAs.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/SaveAs.sh 2012-08-19 12:40:10.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9985,8 +15043,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/UpdatePermissions.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/UpdatePermissions.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/UpdatePermissions.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/UpdatePermissions.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -9996,8 +15054,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/UsePolicy.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/UsePolicy.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/UsePolicy.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/UsePolicy.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10007,8 +15065,8 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/security/tools/policytool/i18n.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/security/tools/policytool/i18n.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/tools/policytool/i18n.sh 2012-08-10 10:37:05.000000000 -0700 ++++ jdk/test/sun/security/tools/policytool/i18n.sh 2012-08-19 12:40:10.000000000 -0700 @@ -46,7 +46,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10018,8 +15076,52 @@ NULL=/dev/null PS=":" FS="/" ---- jdk/test/sun/tools/jconsole/ImmutableResourceTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/tools/jconsole/ImmutableResourceTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/security/util/Oid/S11N.sh 2012-08-10 10:37:06.000000000 -0700 ++++ jdk/test/sun/security/util/Oid/S11N.sh 2012-08-19 12:40:10.000000000 -0700 +@@ -71,7 +71,7 @@ + i[3-6]86 ) + PF="linux-i586" + ;; +- amd64* | x86_64 ) ++ amd64* ) + PF="linux-amd64" + ;; + * ) +@@ -97,29 +97,15 @@ + ;; + esac + +-echo "===================================================" +-echo "Try to set ALT_JAVA_RE_JDK if you see timeout error" +-echo "===================================================" +- + # the test code + + ${TESTJAVA}${FS}bin${FS}javac -target 1.4 -source 1.4 \ + -d . ${TESTSRC}${FS}SerialTest.java || exit 10 + +-# You can set ALT_JAVA_RE_JDK to another location that contains the +-# binaries for older JDK releases. You can set it to a non-existent +-# directory to skip the interop tests between different versions. +- +-if [ "$ALT_JAVA_RE_JDK" = "" ]; then +- JAVA_RE_JDK=/java/re/j2se +-else +- JAVA_RE_JDK=$ALT_JAVA_RE_JDK +-fi +- + OLDJAVA=" +- $JAVA_RE_JDK/1.6.0/latest/binaries/${PF} +- $JAVA_RE_JDK/1.5.0/latest/binaries/${PF} +- $JAVA_RE_JDK/1.4.2/latest/binaries/${PF} ++ /java/re/j2se/1.6.0/latest/binaries/${PF} ++ /java/re/j2se/1.5.0/latest/binaries/${PF} ++ /java/re/j2se/1.4.2/latest/binaries/${PF} + " + + SMALL=" +--- jdk/test/sun/tools/jconsole/ImmutableResourceTest.sh 2012-08-10 10:37:09.000000000 -0700 ++++ jdk/test/sun/tools/jconsole/ImmutableResourceTest.sh 2012-08-19 12:40:10.000000000 -0700 @@ -53,7 +53,7 @@ OS=`uname -s` @@ -10029,8 +15131,8 @@ PATHSEP=":" ;; ---- jdk/test/sun/tools/jconsole/ResourceCheckTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/tools/jconsole/ResourceCheckTest.sh 2011-04-22 23:08:54.000000000 -0700 +--- jdk/test/sun/tools/jconsole/ResourceCheckTest.sh 2012-08-10 10:37:09.000000000 -0700 ++++ jdk/test/sun/tools/jconsole/ResourceCheckTest.sh 2012-08-19 12:40:10.000000000 -0700 @@ -54,7 +54,7 @@ OS=`uname -s` @@ -10040,8 +15142,8 @@ PATHSEP=":" ;; ---- jdk/test/sun/tools/native2ascii/Native2AsciiTests.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/tools/native2ascii/Native2AsciiTests.sh 2011-04-22 23:08:55.000000000 -0700 +--- jdk/test/sun/tools/native2ascii/Native2AsciiTests.sh 2012-08-10 10:37:12.000000000 -0700 ++++ jdk/test/sun/tools/native2ascii/Native2AsciiTests.sh 2012-08-19 12:40:11.000000000 -0700 @@ -33,7 +33,7 @@ case `uname -s` in @@ -10051,8 +15153,8 @@ esac N2A=$TESTJAVA/bin/native2ascii ---- jdk/test/sun/tools/native2ascii/resources/ImmutableResourceTest.sh 2012-05-26 23:29:12.000000000 -0700 -+++ jdk/test/sun/tools/native2ascii/resources/ImmutableResourceTest.sh 2012-05-17 16:18:01.000000000 -0700 +--- jdk/test/sun/tools/native2ascii/resources/ImmutableResourceTest.sh 2012-08-10 10:37:12.000000000 -0700 ++++ jdk/test/sun/tools/native2ascii/resources/ImmutableResourceTest.sh 2012-08-19 12:40:11.000000000 -0700 @@ -56,7 +56,7 @@ OS=`uname -s` @@ -10062,8 +15164,8 @@ PATHSEP=":" ;; ---- langtools/.hgtags 2012-05-26 23:29:10.000000000 -0700 -+++ langtools/.hgtags 2012-05-16 16:10:26.000000000 -0700 +--- langtools/.hgtags 2012-08-10 10:39:19.000000000 -0700 ++++ langtools/.hgtags 2012-08-19 11:53:31.000000000 -0700 @@ -123,6 +123,7 @@ 9425dd4f53d5bfcd992d9aecea0eb7d8b2d4f62b jdk7-b146 d34578643d1c6c752d4a6b5e79c6ab1b60850b4a jdk7u1-b01 @@ -10072,8 +15174,15 @@ cd2cc8b5edb045b950aed46d159b4fb8fc2fd1df jdk7u1-b02 82820a30201dbf4b80f1916f3d0f4a92ad21b61a jdk7u1-b03 baa2c13c70fea3d6e259a34f0903197fdceb64b5 jdk7u1-b04 ---- langtools/test/Makefile 2012-05-26 23:29:10.000000000 -0700 -+++ langtools/test/Makefile 2012-05-16 16:17:05.000000000 -0700 +@@ -197,5 +198,4 @@ + a35ca56cf8d09b92511f0cd71208a2ea05c8a338 jdk7u6-b21 + 4f3aafa690d1fcb18693fc4085049eeffe4778f7 jdk7u6-b22 + dd3e29d8892fcaba6d76431d5fa9d49e7c088f76 jdk7u6-b23 +-a35ca56cf8d09b92511f0cd71208a2ea05c8a338 jdk7u8-b01 +-41bc8da868e58f7182d26b2ab9b6f8a4b09894ed jdk7u8-b02 ++6aac89e84fc96d15bb78b13aa71c9e6b73d7237e jdk7u6-b24 +--- langtools/test/Makefile 2012-08-10 10:39:30.000000000 -0700 ++++ langtools/test/Makefile 2012-08-19 11:53:32.000000000 -0700 @@ -42,6 +42,14 @@ ARCH=i586 endif @@ -10109,8 +15218,8 @@ # Root of all test results TEST_OUTPUT_DIR = $(TEST_ROOT)/../build/$(PLATFORM)-$(ARCH)/test/langtools ---- langtools/test/tools/javac/4846262/Test.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/4846262/Test.sh 2012-05-16 16:17:18.000000000 -0700 +--- langtools/test/tools/javac/4846262/Test.sh 2012-08-10 10:39:38.000000000 -0700 ++++ langtools/test/tools/javac/4846262/Test.sh 2012-08-19 11:53:33.000000000 -0700 @@ -44,7 +44,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10120,8 +15229,8 @@ FS="/" ;; CYGWIN* ) ---- langtools/test/tools/javac/6302184/T6302184.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/6302184/T6302184.sh 2012-05-16 16:17:29.000000000 -0700 +--- langtools/test/tools/javac/6302184/T6302184.sh 2012-08-10 10:39:38.000000000 -0700 ++++ langtools/test/tools/javac/6302184/T6302184.sh 2012-08-19 11:53:33.000000000 -0700 @@ -41,7 +41,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10131,8 +15240,8 @@ FS="/" ;; CYGWIN* ) ---- langtools/test/tools/javac/ClassPathTest/ClassPathTest.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/ClassPathTest/ClassPathTest.sh 2012-05-16 16:17:54.000000000 -0700 +--- langtools/test/tools/javac/ClassPathTest/ClassPathTest.sh 2012-08-10 10:39:41.000000000 -0700 ++++ langtools/test/tools/javac/ClassPathTest/ClassPathTest.sh 2012-08-19 11:53:33.000000000 -0700 @@ -56,7 +56,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10142,8 +15251,8 @@ FS="/" ;; Windows* ) ---- langtools/test/tools/javac/ExtDirs/ExtDirs.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/ExtDirs/ExtDirs.sh 2012-05-16 16:18:08.000000000 -0700 +--- langtools/test/tools/javac/ExtDirs/ExtDirs.sh 2012-08-10 10:39:43.000000000 -0700 ++++ langtools/test/tools/javac/ExtDirs/ExtDirs.sh 2012-08-19 11:53:33.000000000 -0700 @@ -54,7 +54,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10153,8 +15262,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javac/MissingInclude.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/MissingInclude.sh 2012-05-16 16:18:28.000000000 -0700 +--- langtools/test/tools/javac/MissingInclude.sh 2012-08-10 10:39:44.000000000 -0700 ++++ langtools/test/tools/javac/MissingInclude.sh 2012-08-19 11:53:34.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10164,8 +15273,8 @@ FS="/" ;; Windows* ) ---- langtools/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh 2012-05-16 16:18:38.000000000 -0700 +--- langtools/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh 2012-08-10 10:39:45.000000000 -0700 ++++ langtools/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh 2012-08-19 11:53:34.000000000 -0700 @@ -52,7 +52,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10175,8 +15284,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javac/T5090006/compiler.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/T5090006/compiler.sh 2012-05-16 16:33:41.000000000 -0700 +--- langtools/test/tools/javac/T5090006/compiler.sh 2012-08-10 10:39:47.000000000 -0700 ++++ langtools/test/tools/javac/T5090006/compiler.sh 2012-08-19 11:53:34.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10186,8 +15295,8 @@ FS="/" ;; Windows* ) ---- langtools/test/tools/javac/apt.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/apt.sh 2012-05-16 16:33:47.000000000 -0700 +--- langtools/test/tools/javac/apt.sh 2012-08-10 10:39:53.000000000 -0700 ++++ langtools/test/tools/javac/apt.sh 2012-08-19 11:53:34.000000000 -0700 @@ -38,7 +38,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10197,8 +15306,8 @@ NULL=/dev/null PS=":" FS="/" ---- langtools/test/tools/javac/constDebug/ConstDebug.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/constDebug/ConstDebug.sh 2012-05-16 16:33:56.000000000 -0700 +--- langtools/test/tools/javac/constDebug/ConstDebug.sh 2012-08-10 10:39:55.000000000 -0700 ++++ langtools/test/tools/javac/constDebug/ConstDebug.sh 2012-08-19 11:53:34.000000000 -0700 @@ -47,7 +47,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10208,8 +15317,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javac/fatalErrors/NoJavaLang.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/fatalErrors/NoJavaLang.sh 2012-05-16 16:34:05.000000000 -0700 +--- langtools/test/tools/javac/fatalErrors/NoJavaLang.sh 2012-08-10 10:40:03.000000000 -0700 ++++ langtools/test/tools/javac/fatalErrors/NoJavaLang.sh 2012-08-19 11:53:35.000000000 -0700 @@ -48,7 +48,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10219,8 +15328,8 @@ FS="/" ;; CYGWIN* ) ---- langtools/test/tools/javac/innerClassFile/Driver.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/innerClassFile/Driver.sh 2012-05-16 16:34:21.000000000 -0700 +--- langtools/test/tools/javac/innerClassFile/Driver.sh 2012-08-10 10:40:14.000000000 -0700 ++++ langtools/test/tools/javac/innerClassFile/Driver.sh 2012-08-19 11:53:35.000000000 -0700 @@ -53,7 +53,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10230,8 +15339,8 @@ FS="/" ;; Windows* ) ---- langtools/test/tools/javac/javazip/Test.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/javazip/Test.sh 2012-05-16 16:34:29.000000000 -0700 +--- langtools/test/tools/javac/javazip/Test.sh 2012-08-10 10:40:14.000000000 -0700 ++++ langtools/test/tools/javac/javazip/Test.sh 2012-08-19 11:53:35.000000000 -0700 @@ -41,7 +41,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10241,8 +15350,8 @@ FS="/" SCR=`pwd` ;; ---- langtools/test/tools/javac/links/links.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/links/links.sh 2012-05-16 16:34:36.000000000 -0700 +--- langtools/test/tools/javac/links/links.sh 2012-08-10 10:40:15.000000000 -0700 ++++ langtools/test/tools/javac/links/links.sh 2012-08-19 11:53:36.000000000 -0700 @@ -53,7 +53,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10252,8 +15361,8 @@ NULL=/dev/null PS=":" FS="/" ---- langtools/test/tools/javac/newlines/Newlines.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/newlines/Newlines.sh 2012-05-16 16:34:54.000000000 -0700 +--- langtools/test/tools/javac/newlines/Newlines.sh 2012-08-10 10:40:17.000000000 -0700 ++++ langtools/test/tools/javac/newlines/Newlines.sh 2012-08-19 11:53:36.000000000 -0700 @@ -50,7 +50,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10263,8 +15372,8 @@ FS="/" ;; Windows* ) ---- langtools/test/tools/javac/stackmap/T4955930.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/stackmap/T4955930.sh 2012-05-16 16:35:11.000000000 -0700 +--- langtools/test/tools/javac/stackmap/T4955930.sh 2012-08-10 10:40:22.000000000 -0700 ++++ langtools/test/tools/javac/stackmap/T4955930.sh 2012-08-19 11:53:36.000000000 -0700 @@ -41,7 +41,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10274,28 +15383,19 @@ FS="/" ;; Windows_95 | Windows_98 | Windows_NT ) ---- langtools/test/tools/javac/unicode/SupplementaryJavaID6.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javac/unicode/SupplementaryJavaID6.sh 2012-05-19 10:56:30.000000000 -0700 -@@ -66,6 +66,17 @@ - exit 0; - fi - ;; -+ *BSD ) -+ if [ -d /usr/share/locale/en_US.UTF-8 -o -d /usr/share/locale/en_US.utf8 ] -+ then -+ ENV="env LANG=en_US.UTF-8" -+ PS=":" -+ FS="/" -+ else -+ echo "As there is no en_US.UTF-8 locale available on this system, the compilation of the test case may or may not fail. Ignoring this test." -+ exit 0; -+ fi -+ ;; - Windows_98 | Windows_ME ) - echo "As Windows 98/Me do not provide Unicode-aware file system, the compilation of the test case is expected to fail on these platforms. Ignoring this test." - exit 0; ---- langtools/test/tools/javah/6257087/foo.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javah/6257087/foo.sh 2012-05-16 16:35:18.000000000 -0700 +--- langtools/test/tools/javac/unicode/SupplementaryJavaID6.sh 2012-08-10 10:40:25.000000000 -0700 ++++ langtools/test/tools/javac/unicode/SupplementaryJavaID6.sh 2012-08-19 11:53:36.000000000 -0700 +@@ -55,7 +55,7 @@ + # set platform-dependent variables + OS=`uname -s` + case "$OS" in +- SunOS | Linux | Darwin ) ++ SunOS | Linux | Darwin | *BSD ) + if [ -d /usr/lib/locale/en_US.UTF-8 -o -d /usr/lib/locale/en_US.utf8 ] + then + ENV="env LANG=en_US.UTF-8" +--- langtools/test/tools/javah/6257087/foo.sh 2012-08-10 10:40:28.000000000 -0700 ++++ langtools/test/tools/javah/6257087/foo.sh 2012-08-19 11:53:36.000000000 -0700 @@ -41,7 +41,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10305,8 +15405,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javah/ConstMacroTest.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javah/ConstMacroTest.sh 2012-05-16 16:35:25.000000000 -0700 +--- langtools/test/tools/javah/ConstMacroTest.sh 2012-08-10 10:40:28.000000000 -0700 ++++ langtools/test/tools/javah/ConstMacroTest.sh 2012-08-19 11:53:36.000000000 -0700 @@ -56,7 +56,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10316,8 +15416,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javah/MissingParamClassTest.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javah/MissingParamClassTest.sh 2012-05-16 16:35:40.000000000 -0700 +--- langtools/test/tools/javah/MissingParamClassTest.sh 2012-08-10 10:40:28.000000000 -0700 ++++ langtools/test/tools/javah/MissingParamClassTest.sh 2012-08-19 11:53:36.000000000 -0700 @@ -58,7 +58,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10327,8 +15427,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javah/ReadOldClass.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javah/ReadOldClass.sh 2012-05-16 16:35:57.000000000 -0700 +--- langtools/test/tools/javah/ReadOldClass.sh 2012-08-10 10:40:28.000000000 -0700 ++++ langtools/test/tools/javah/ReadOldClass.sh 2012-08-19 11:53:36.000000000 -0700 @@ -43,7 +43,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10338,8 +15438,8 @@ PS=":" FS="/" ;; ---- langtools/test/tools/javap/pathsep.sh 2012-05-26 23:29:11.000000000 -0700 -+++ langtools/test/tools/javap/pathsep.sh 2012-05-16 16:36:14.000000000 -0700 +--- langtools/test/tools/javap/pathsep.sh 2012-08-10 10:40:29.000000000 -0700 ++++ langtools/test/tools/javap/pathsep.sh 2012-08-19 11:53:36.000000000 -0700 @@ -40,7 +40,7 @@ # set platform-dependent variables OS=`uname -s` @@ -10349,3 +15449,348 @@ FS="/" ;; Windows* ) +--- make/scripts/hgforest.sh 2012-08-10 09:07:04.000000000 -0700 ++++ make/scripts/hgforest.sh 2012-08-19 11:38:54.000000000 -0700 +@@ -1,7 +1,7 @@ + #!/bin/sh + + # +-# Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved. ++# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved. + # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + # + # This code is free software; you can redistribute it and/or modify it +@@ -24,8 +24,6 @@ + # + + # Shell script for a fast parallel forest command +-command="$1" +-pull_extra_base="$2" + + tmp=/tmp/forest.$$ + rm -f -r ${tmp} +@@ -37,58 +35,40 @@ + + # Only look in specific locations for possible forests (avoids long searches) + pull_default="" +-repos="" +-repos_extra="" +-if [ "${command}" = "clone" -o "${command}" = "fclone" ] ; then ++if [ "$1" = "clone" -o "$1" = "fclone" ] ; then + subrepos="corba jaxp jaxws langtools jdk hotspot" + if [ -f .hg/hgrc ] ; then + pull_default=`hg paths default` +- if [ "${pull_default}" = "" ] ; then +- echo "ERROR: Need initial clone with 'hg paths default' defined" +- exit 1 +- fi + fi + if [ "${pull_default}" = "" ] ; then +- echo "ERROR: Need initial repository to use this script" ++ echo "ERROR: Need initial clone with 'hg paths default' defined" + exit 1 + fi ++ repos="" + for i in ${subrepos} ; do + if [ ! -f ${i}/.hg/hgrc ] ; then + repos="${repos} ${i}" + fi + done +- if [ "${pull_extra_base}" != "" ] ; then +- subrepos_extra="jdk/src/closed jdk/make/closed jdk/test/closed hotspot/src/closed hotspot/test/closed deploy install sponsors pubs" +- pull_default_tail=`echo ${pull_default} | sed -e 's@^.*://[^/]*/\(.*\)@\1@'` +- pull_extra="${pull_extra_base}/${pull_default_tail}" +- for i in ${subrepos_extra} ; do +- if [ ! -f ${i}/.hg/hgrc ] ; then +- repos_extra="${repos_extra} ${i}" +- fi +- done +- fi + at_a_time=2 +- # Any repos to deal with? +- if [ "${repos}" = "" -a "${repos_extra}" = "" ] ; then +- echo "No repositories to clone." +- exit +- fi + else + hgdirs=`ls -d ./.hg ./*/.hg ./*/*/.hg ./*/*/*/.hg ./*/*/*/*/.hg 2>/dev/null` + # Derive repository names from the .hg directory locations ++ repos="" + for i in ${hgdirs} ; do + repos="${repos} `echo ${i} | sed -e 's@/.hg$@@'`" + done + at_a_time=8 +- # Any repos to deal with? +- if [ "${repos}" = "" ] ; then +- echo "No repositories to process." +- exit +- fi + fi + +-# Echo out what repositories we will clone +-echo "# Repos: ${repos} ${repos_extra}" ++# Any repos to deal with? ++if [ "${repos}" = "" ] ; then ++ echo "No repositories to process." ++ exit ++fi ++ ++# Echo out what repositories we will process ++echo "# Repos: ${repos}" + + # Run the supplied command on all repos in parallel, save output until end + n=0 +@@ -97,9 +77,8 @@ + n=`expr ${n} '+' 1` + ( + ( +- if [ "${command}" = "clone" -o "${command}" = "fclone" ] ; then +- pull_newrepo="`echo ${pull_default}/${i} | sed -e 's@\([^:]/\)//*@\1@g'`" +- cline="hg clone ${pull_newrepo} ${i}" ++ if [ "$1" = "clone" -o "$1" = "fclone" ] ; then ++ cline="hg $* ${pull_default}/${i} ${i}" + echo "# ${cline}" + ( eval "${cline}" ) + else +@@ -113,29 +92,10 @@ + sleep 5 + fi + done ++ + # Wait for all hg commands to complete + wait + +-if [ "${repos_extra}" != "" ] ; then +- for i in ${repos_extra} ; do +- echo "Starting on ${i}" +- n=`expr ${n} '+' 1` +- ( +- ( +- pull_newextrarepo="`echo ${pull_extra}/${i} | sed -e 's@\([^:]/\)//*@\1@g'`" +- cline="hg clone ${pull_newextrarepo} ${i}" +- echo "# ${cline}" +- ( eval "${cline}" ) +- echo "# exit code $?" +- ) > ${tmp}/repo.${n} 2>&1 ; cat ${tmp}/repo.${n} ) & +- if [ `expr ${n} '%' ${at_a_time}` -eq 0 ] ; then +- sleep 5 +- fi +- done +- # Wait for all hg commands to complete +- wait +-fi +- + # Cleanup + rm -f -r ${tmp} + +--- make/scripts/normalizer.pl 2012-08-10 09:07:04.000000000 -0700 ++++ make/scripts/normalizer.pl 1969-12-31 16:00:00.000000000 -0800 +@@ -1,208 +0,0 @@ +-#!/usr/bin/perl +- +-# +-# Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved. +-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +-# +-# This code is free software; you can redistribute it and/or modify it +-# under the terms of the GNU General Public License version 2 only, as +-# published by the Free Software Foundation. +-# +-# This code is distributed in the hope that it will be useful, but WITHOUT +-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +-# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +-# version 2 for more details (a copy is included in the LICENSE file that +-# accompanied this code). +-# +-# You should have received a copy of the GNU General Public License version +-# 2 along with this work; if not, write to the Free Software Foundation, +-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +-# +-# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +-# or visit www.oracle.com if you need additional information or have any +-# questions. +-# +- +-# +-# Parses java files: +-# 1. Removes from the end of lines spaces and TABs +-# 2. Replaces TABs by spaces +-# 3. Replaces all NewLine separators by Unix NewLine separators +-# 4. Makes one and only one empty line at the end of each file +- +-if ($#ARGV < 0) { +- &usage; +- +- die; +-} +- +-use Cwd 'abs_path'; +- +-my @extensions = ("java"); +- +-# Read options +-my $dirpos = 0; +- +-while ($dirpos < $#ARGV) { +- if ($ARGV[$dirpos] eq "-e") { +- @extensions = split(/,/, $ARGV[$dirpos + 1]); +- } else { +- last; +- } +- +- $dirpos += 2; +-} +- +-if ($dirpos > $#ARGV) { +- &usage; +- +- die; +-} +- +-use Cwd; +-my $currdir = getcwd; +- +-my $allfiles = 0; +- +-my $filecount = 0; +- +-my @tabvalues; +- +-# Init tabvalues +-push (@tabvalues, " "); +- +-for (my $i = 1; $i < 8; $i++) { +- push(@tabvalues, $tabvalues[$i - 1] . " "); +-} +- +-open(FILELIST, ">$currdir/filelist") or die "Failed while open $currdir/filelist: $!\n"; +- +-while ($dirpos <= $#ARGV) { +- use File::Find; +- +- find(\&parse_file, abs_path($ARGV[$dirpos])); +- +- $dirpos += 1; +-} +- +-close(FILELIST); +- +-use Cwd 'chdir'; +-chdir $currdir; +- +-print "Checked $allfiles file(s)\n"; +-print "Modified $filecount file(s)\n"; +-print "See results in the file $currdir/filelist\n"; +- +-sub parse_file { +- my $filename = $File::Find::name; +- +- # Skip directories +- return if -d; +- +- # Skip SCCS files +- return if ($filename =~ /\/SCCS\//); +- +- # Skip files with invalid extensions +- my $accepted = 0; +- foreach my $ext (@extensions) { +- if ($_ =~ /\.$ext$/i) { +- $accepted = 1; +- +- last; +- } +- } +- return if ($accepted == 0); +- +- use File::Basename; +- my $dirname = dirname($filename); +- +- use Cwd 'chdir'; +- chdir $dirname; +- +- open(FILE, $filename) or die "Failed while open $filename: $!\n"; +- +- # Read file +- my @content; +- my $line; +- my $emptylinescount = 0; +- my $modified = 0; +- +- while ($line = <FILE>) { +- my $originalline = $line; +- +- # Process line +- +- # Remove from the end of the line spaces and return character +- while ($line =~ /\s$/) { +- chop($line); +- } +- +- # Replace TABs +- for (my $i = 0; $i < length($line); $i++) { +- if (substr($line, $i, 1) =~ /\t/) { +- $line = substr($line, 0, $i) . $tabvalues[7 - ($i % 8)] . substr($line, $i + 1); +- } +- } +- +- if (length($line) == 0) { +- $emptylinescount++; +- } else { +- while ($emptylinescount > 0) { +- push(@content, ""); +- +- $emptylinescount--; +- } +- +- push(@content, $line); +- } +- +- if ($originalline ne ($line . "\n")) { +- $modified = 1; +- } +- +- } +- +- $allfiles++; +- +- if ($emptylinescount > 0) { +- $modified = 1; +- } +- +- close(FILE); +- +- if ($modified != 0) { +- # Write file +- open(FILE, ">$filename") or die "Failed while open $filename: $!\n"; +- +- for (my $i = 0; $i <= $#content; $i++) { +- print FILE "$content[$i]\n"; +- } +- +- close(FILE); +- +- # Print name from current dir +- if (index($filename, $currdir) == 0) { +- print FILELIST substr($filename, length($currdir) + 1); +- } else { +- print FILELIST $filename; +- } +- print FILELIST "\n"; +- +- $filecount++; +- +- print "$filename: modified\n"; +- } +-} +- +-sub usage { +- print "Usage:\n"; +- print " normalizer.pl [-options] <dir> [dir2 dir3 ...]\n"; +- print " Available options:\n"; +- print " -e comma separated files extensions. By default accepts only java files\n"; +- print "\n"; +- print "Examples:\n"; +- print " normalizer.pl -e c,cpp,h,hpp .\n"; +-} +- +- diff --git a/java/openjdk7/files/patch-src-os-bsd-vm-attachListener_bsd.cpp b/java/openjdk7/files/patch-src-os-bsd-vm-attachListener_bsd.cpp deleted file mode 100644 index 9088cf568367..000000000000 --- a/java/openjdk7/files/patch-src-os-bsd-vm-attachListener_bsd.cpp +++ /dev/null @@ -1,16 +0,0 @@ -$FreeBSD$ - ---- hotspot/src/os/bsd/vm/attachListener_bsd.cpp.orig 2012-06-05 23:51:31.000000000 -0700 -+++ hotspot/src/os/bsd/vm/attachListener_bsd.cpp 2012-06-05 23:54:28.000000000 -0700 -@@ -208,7 +208,10 @@ - if (res == 0) { - RESTARTABLE(::chmod(initial_path, S_IREAD|S_IWRITE), res); - if (res == 0) { -- res = ::rename(initial_path, path); -+ RESTARTABLE(::chown(initial_path, geteuid(), getegid()), res); -+ if (res == 0) { -+ res = ::rename(initial_path, path); -+ } - } - } - if (res == -1) { diff --git a/java/openjdk7/files/patch-src-solaris-native-java-net-NetworkInterface.c b/java/openjdk7/files/patch-src-solaris-native-java-net-NetworkInterface.c deleted file mode 100644 index 8a977e6d87d7..000000000000 --- a/java/openjdk7/files/patch-src-solaris-native-java-net-NetworkInterface.c +++ /dev/null @@ -1,17 +0,0 @@ -$FreeBSD$ - ---- jdk/src/solaris/native/java/net/NetworkInterface.c Mon Jun 27 22:08:16 2011 -0700 -+++ jdk/src/solaris/native/java/net/NetworkInterface.c Thu Jul 07 23:37:05 2011 -0700 -@@ -1968,7 +1968,11 @@ - return -1; - } - -- return if2.ifr_flags; -+#ifdef __FreeBSD__ -+ return ((if2.ifr_flags & 0xffff) | (if2.ifr_flagshigh << 16)); -+#else -+ return (((int) if2.ifr_flags) & 0xffff); -+#endif - } - - #endif diff --git a/java/openjdk7/files/patch-u5 b/java/openjdk7/files/patch-u5 deleted file mode 100644 index 6bf0d1726637..000000000000 --- a/java/openjdk7/files/patch-u5 +++ /dev/null @@ -1,2985 +0,0 @@ -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/interceptors/ClientRequestInfoImpl.java ---- corba/src/share/classes/com/sun/corba/se/impl/interceptors/ClientRequestInfoImpl.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/interceptors/ClientRequestInfoImpl.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -217,7 +217,7 @@ - - // ClientRequestInfo validity table (see ptc/00-08-06 table 21-1). - // Note: These must be in the same order as specified in contants. -- protected static final boolean validCall[][] = { -+ private static final boolean validCall[][] = { - // LEGEND: - // s_req = send_request r_rep = receive_reply - // s_pol = send_poll r_exc = receive_exception -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/interceptors/ServerRequestInfoImpl.java ---- corba/src/share/classes/com/sun/corba/se/impl/interceptors/ServerRequestInfoImpl.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/interceptors/ServerRequestInfoImpl.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2000, 2003, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -195,7 +195,7 @@ - - // ServerRequestInfo validity table (see ptc/00-08-06 table 21-2). - // Note: These must be in the same order as specified in contants. -- protected static final boolean validCall[][] = { -+ private static final boolean validCall[][] = { - // LEGEND: - // r_rsc = receive_request_service_contexts - // r_req = receive_request -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/javax/rmi/CORBA/Util.java ---- corba/src/share/classes/com/sun/corba/se/impl/javax/rmi/CORBA/Util.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/javax/rmi/CORBA/Util.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1999, 2004, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -130,10 +130,23 @@ - private UtilSystemException utilWrapper = UtilSystemException.get( - CORBALogDomains.RPC_ENCODING); - -- public static Util instance = null; -+ private static Util instance = null; - - public Util() { -- instance = this; -+ setInstance(this); -+ } -+ -+ private static void setInstance( Util util ) { -+ assert instance == null : "Instance already defined"; -+ instance = util; -+ } -+ -+ public static Util getInstance() { -+ return instance; -+ } -+ -+ public static boolean isInstanceDefined() { -+ return instance != null; - } - - // Used by TOAFactory.shutdown to unexport all targets for this -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/oa/poa/POAPolicyMediatorBase_R.java ---- corba/src/share/classes/com/sun/corba/se/impl/oa/poa/POAPolicyMediatorBase_R.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/oa/poa/POAPolicyMediatorBase_R.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -93,7 +93,7 @@ - - activeObjectMap.putServant( servant, entry ) ; - -- if (Util.instance != null) { -+ if (Util.isInstanceDefined()) { - POAManagerImpl pm = (POAManagerImpl)poa.the_POAManager() ; - POAFactory factory = pm.getFactory() ; - factory.registerPOAForServant(poa, servant); -@@ -129,7 +129,7 @@ - - activeObjectMap.remove(key); - -- if (Util.instance != null) { -+ if (Util.isInstanceDefined()) { - POAManagerImpl pm = (POAManagerImpl)poa.the_POAManager() ; - POAFactory factory = pm.getFactory() ; - factory.unregisterPOAForServant(poa, s); -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/oa/toa/TOAFactory.java ---- corba/src/share/classes/com/sun/corba/se/impl/oa/toa/TOAFactory.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/oa/toa/TOAFactory.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2002, 2003, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -78,8 +78,8 @@ - - public void shutdown( boolean waitForCompletion ) - { -- if (Util.instance != null) { -- Util.instance.unregisterTargetsForORB(orb); -+ if (Util.isInstanceDefined()) { -+ Util.getInstance().unregisterTargetsForORB(orb); - } - } - -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/orb/ParserTable.java ---- corba/src/share/classes/com/sun/corba/se/impl/orb/ParserTable.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/orb/ParserTable.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2002, 2006, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -106,7 +106,9 @@ - - public ParserData[] getParserData() - { -- return parserData ; -+ ParserData[] parserArray = new ParserData[parserData.length]; -+ System.arraycopy(parserData, 0, parserArray, 0, parserData.length); -+ return parserArray; - } - - private ParserTable() { -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3.java ---- corba/src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2000, 2002, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -62,7 +62,7 @@ - // legal use of '.' in a Java name. - - public static final RepositoryIdCache_1_3 cache = new RepositoryIdCache_1_3(); -- public static final byte[] IDL_IDENTIFIER_CHARS = { -+ private static final byte[] IDL_IDENTIFIER_CHARS = { - - // 0 1 2 3 4 5 6 7 8 9 a b c d e f - 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 00-0f -@@ -180,7 +180,7 @@ - public static final String kRemoteTypeStr = ""; - public static final String kRemoteValueRepID = ""; - -- public static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); -+ private static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); - - static { - kSpecialArrayTypeStrings.put("CORBA.WStringValue", new StringBuffer(java.lang.String.class.getName())); -@@ -189,7 +189,7 @@ - - } - -- public static final Hashtable kSpecialCasesRepIDs = new Hashtable(); -+ private static final Hashtable kSpecialCasesRepIDs = new Hashtable(); - - static { - kSpecialCasesRepIDs.put(java.lang.String.class, kWStringValueRepID); -@@ -197,7 +197,7 @@ - kSpecialCasesRepIDs.put(java.rmi.Remote.class, kRemoteValueRepID); - } - -- public static final Hashtable kSpecialCasesStubValues = new Hashtable(); -+ private static final Hashtable kSpecialCasesStubValues = new Hashtable(); - - static { - kSpecialCasesStubValues.put(java.lang.String.class, kWStringStubValue); -@@ -209,7 +209,7 @@ - } - - -- public static final Hashtable kSpecialCasesVersions = new Hashtable(); -+ private static final Hashtable kSpecialCasesVersions = new Hashtable(); - - static { - kSpecialCasesVersions.put(java.lang.String.class, kWStringValueHash); -@@ -220,7 +220,7 @@ - kSpecialCasesVersions.put(java.rmi.Remote.class, kRemoteValueHash); - } - -- public static final Hashtable kSpecialCasesClasses = new Hashtable(); -+ private static final Hashtable kSpecialCasesClasses = new Hashtable(); - - static { - kSpecialCasesClasses.put(kWStringTypeStr, java.lang.String.class); -@@ -232,7 +232,7 @@ - //kSpecialCasesClasses.put(kRemoteTypeStr, java.rmi.Remote.class); - } - -- public static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); -+ private static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); - - static { - kSpecialCasesArrayPrefix.put(java.lang.String.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); -@@ -243,7 +243,7 @@ - kSpecialCasesArrayPrefix.put(java.rmi.Remote.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); - } - -- public static final Hashtable kSpecialPrimitives = new Hashtable(); -+ private static final Hashtable kSpecialPrimitives = new Hashtable(); - - static { - kSpecialPrimitives.put("int","long"); -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3_1.java ---- corba/src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3_1.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/orbutil/RepositoryId_1_3_1.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2001, 2002, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -63,7 +63,7 @@ - // uniformly, and is safe because that is the only - // legal use of '.' in a Java name. - -- public static final byte[] IDL_IDENTIFIER_CHARS = { -+ private static final byte[] IDL_IDENTIFIER_CHARS = { - - // 0 1 2 3 4 5 6 7 8 9 a b c d e f - 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 00-0f -@@ -198,7 +198,7 @@ - public static final String kRemoteTypeStr = ""; - public static final String kRemoteValueRepID = ""; - -- public static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); -+ private static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); - - static { - kSpecialArrayTypeStrings.put("CORBA.WStringValue", new StringBuffer(java.lang.String.class.getName())); -@@ -207,7 +207,7 @@ - - } - -- public static final Hashtable kSpecialCasesRepIDs = new Hashtable(); -+ private static final Hashtable kSpecialCasesRepIDs = new Hashtable(); - - static { - kSpecialCasesRepIDs.put(java.lang.String.class, kWStringValueRepID); -@@ -215,7 +215,7 @@ - kSpecialCasesRepIDs.put(java.rmi.Remote.class, kRemoteValueRepID); - } - -- public static final Hashtable kSpecialCasesStubValues = new Hashtable(); -+ private static final Hashtable kSpecialCasesStubValues = new Hashtable(); - - static { - kSpecialCasesStubValues.put(java.lang.String.class, kWStringStubValue); -@@ -227,7 +227,7 @@ - } - - -- public static final Hashtable kSpecialCasesVersions = new Hashtable(); -+ private static final Hashtable kSpecialCasesVersions = new Hashtable(); - - static { - kSpecialCasesVersions.put(java.lang.String.class, kWStringValueHash); -@@ -238,7 +238,7 @@ - kSpecialCasesVersions.put(java.rmi.Remote.class, kRemoteValueHash); - } - -- public static final Hashtable kSpecialCasesClasses = new Hashtable(); -+ private static final Hashtable kSpecialCasesClasses = new Hashtable(); - - static { - kSpecialCasesClasses.put(kWStringTypeStr, java.lang.String.class); -@@ -250,7 +250,7 @@ - //kSpecialCasesClasses.put(kRemoteTypeStr, java.rmi.Remote.class); - } - -- public static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); -+ private static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); - - static { - kSpecialCasesArrayPrefix.put(java.lang.String.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); -@@ -261,7 +261,7 @@ - kSpecialCasesArrayPrefix.put(java.rmi.Remote.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); - } - -- public static final Hashtable kSpecialPrimitives = new Hashtable(); -+ private static final Hashtable kSpecialPrimitives = new Hashtable(); - - static { - kSpecialPrimitives.put("int","long"); -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/protocol/LocalClientRequestDispatcherBase.java ---- corba/src/share/classes/com/sun/corba/se/impl/protocol/LocalClientRequestDispatcherBase.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/protocol/LocalClientRequestDispatcherBase.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2002, 2003, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -52,7 +52,7 @@ - - // If isNextIsLocalValid.get() == Boolean.TRUE, - // the next call to isLocal should be valid -- protected static ThreadLocal isNextCallValid = new ThreadLocal() { -+ private static final ThreadLocal isNextCallValid = new ThreadLocal() { - protected synchronized Object initialValue() { - return Boolean.TRUE; - } -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/impl/util/RepositoryId.java ---- corba/src/share/classes/com/sun/corba/se/impl/util/RepositoryId.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/impl/util/RepositoryId.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2004, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -57,7 +57,7 @@ - // uniformly, and is safe because that is the only - // legal use of '.' in a Java name. - -- public static final byte[] IDL_IDENTIFIER_CHARS = { -+ private static final byte[] IDL_IDENTIFIER_CHARS = { - - // 0 1 2 3 4 5 6 7 8 9 a b c d e f - 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 00-0f -@@ -95,7 +95,7 @@ - private static IdentityHashtable classIDLToRepStr = new IdentityHashtable(); - private static IdentityHashtable classSeqToRepStr = new IdentityHashtable(); - -- private static IdentityHashtable repStrToByteArray = new IdentityHashtable(); -+ private static final IdentityHashtable repStrToByteArray = new IdentityHashtable(); - private static Hashtable repStrToClass = new Hashtable(); - - private String repId = null; -@@ -192,7 +192,7 @@ - public static final String kRemoteTypeStr = ""; - public static final String kRemoteValueRepID = ""; - -- public static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); -+ private static final Hashtable kSpecialArrayTypeStrings = new Hashtable(); - - static { - kSpecialArrayTypeStrings.put("CORBA.WStringValue", new StringBuffer(java.lang.String.class.getName())); -@@ -201,7 +201,7 @@ - - } - -- public static final Hashtable kSpecialCasesRepIDs = new Hashtable(); -+ private static final Hashtable kSpecialCasesRepIDs = new Hashtable(); - - static { - kSpecialCasesRepIDs.put(java.lang.String.class, kWStringValueRepID); -@@ -209,7 +209,7 @@ - kSpecialCasesRepIDs.put(java.rmi.Remote.class, kRemoteValueRepID); - } - -- public static final Hashtable kSpecialCasesStubValues = new Hashtable(); -+ private static final Hashtable kSpecialCasesStubValues = new Hashtable(); - - static { - kSpecialCasesStubValues.put(java.lang.String.class, kWStringStubValue); -@@ -221,7 +221,7 @@ - } - - -- public static final Hashtable kSpecialCasesVersions = new Hashtable(); -+ private static final Hashtable kSpecialCasesVersions = new Hashtable(); - - static { - kSpecialCasesVersions.put(java.lang.String.class, kWStringValueHash); -@@ -232,7 +232,7 @@ - kSpecialCasesVersions.put(java.rmi.Remote.class, kRemoteValueHash); - } - -- public static final Hashtable kSpecialCasesClasses = new Hashtable(); -+ private static final Hashtable kSpecialCasesClasses = new Hashtable(); - - static { - kSpecialCasesClasses.put(kWStringTypeStr, java.lang.String.class); -@@ -244,7 +244,7 @@ - //kSpecialCasesClasses.put(kRemoteTypeStr, java.rmi.Remote.class); - } - -- public static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); -+ private static final Hashtable kSpecialCasesArrayPrefix = new Hashtable(); - - static { - kSpecialCasesArrayPrefix.put(java.lang.String.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); -@@ -255,7 +255,7 @@ - kSpecialCasesArrayPrefix.put(java.rmi.Remote.class, kValuePrefix + kSequencePrefix + kCORBAPrefix); - } - -- public static final Hashtable kSpecialPrimitives = new Hashtable(); -+ private static final Hashtable kSpecialPrimitives = new Hashtable(); - - static { - kSpecialPrimitives.put("int","long"); -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/com/sun/corba/se/spi/logging/CORBALogDomains.java ---- corba/src/share/classes/com/sun/corba/se/spi/logging/CORBALogDomains.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/com/sun/corba/se/spi/logging/CORBALogDomains.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -58,7 +58,7 @@ - private CORBALogDomains() {} - - // Top level log domain for CORBA -- public static String TOP_LEVEL_DOMAIN = "javax.enterprise.resource.corba"; -+ public static final String TOP_LEVEL_DOMAIN = "javax.enterprise.resource.corba"; - - public static final String RPC = "rpc" ; - -diff -r 6a262c36caeb -r 2e5e8c37d787 src/share/classes/sun/rmi/rmic/iiop/IDLNames.java ---- corba/src/share/classes/sun/rmi/rmic/iiop/IDLNames.java Thu Feb 23 15:14:14 2012 -0800 -+++ corba/src/share/classes/sun/rmi/rmic/iiop/IDLNames.java Tue Feb 28 17:00:14 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2007, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -71,6 +71,34 @@ - (byte)'F', - }; - -+ // Legal IDL Identifier characters (1 = legal). Note -+ // that '.' (2E) is marked as legal even though it is -+ // not legal in IDL. This allows us to treat a fully -+ // qualified Java name with '.' package separators -+ // uniformly, and is safe because that is the only -+ // legal use of '.' in a Java name. -+ -+ private static final byte[] IDL_IDENTIFIER_CHARS = { -+ -+ // 0 1 2 3 4 5 6 7 8 9 a b c d e f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 00-0f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 10-1f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,1,0, // 20-2f -+ 1,1,1,1, 1,1,1,1, 1,1,0,0, 0,0,0,0, // 30-3f -+ 0,1,1,1, 1,1,1,1, 1,1,1,1, 1,1,1,1, // 40-4f -+ 1,1,1,1, 1,1,1,1, 1,1,1,0, 0,0,0,1, // 50-5f -+ 0,1,1,1, 1,1,1,1, 1,1,1,1, 1,1,1,1, // 60-6f -+ 1,1,1,1, 1,1,1,1, 1,1,1,0, 0,0,0,0, // 70-7f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 80-8f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // 90-9f -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // a0-af -+ 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0,0,0, // b0-bf -+ 1,1,1,1, 1,1,1,1, 1,1,1,1, 1,1,1,1, // c0-cf -+ 0,1,1,1, 1,1,1,0, 1,1,1,1, 1,0,0,1, // d0-df -+ 1,1,1,1, 1,1,1,1, 1,1,1,1, 1,1,1,1, // e0-ef -+ 0,1,1,1, 1,1,1,0, 1,1,1,1, 1,0,0,1, // f0-ff -+ }; -+ - //_____________________________________________________________________ - // Public Interfaces - //_____________________________________________________________________ -@@ -139,7 +167,7 @@ - result = replace(result,"x\\U","U"); - - // Now see if we have any remaining illegal characters (see -- // RepositoryId.IDL_IDENTIFIER_CHARS array)... -+ // IDL_IDENTIFIER_CHARS array)... - - int length = result.length(); - StringBuffer buffer = null; -@@ -148,7 +176,7 @@ - - char c = result.charAt(i); - -- if (c > 255 || RepositoryId.IDL_IDENTIFIER_CHARS[c] == 0) { -+ if (c > 255 || IDL_IDENTIFIER_CHARS[c] == 0) { - - // We gotta convert. Have we already started? - -diff -r 149b6bbf77ff -r 6a7aac2ae8db src/share/vm/compiler/compilerOracle.cpp ---- hotspot/src/share/vm/compiler/compilerOracle.cpp Fri Mar 23 10:43:32 2012 -0700 -+++ hotspot/src/share/vm/compiler/compilerOracle.cpp Thu Mar 29 13:22:24 2012 -0400 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -551,13 +551,22 @@ - } - - static const char* cc_file() { -- if (CompileCommandFile == NULL) -+#ifdef ASSERT -+ if (CompileCommandFile == NULL) { - return ".hotspot_compiler"; -+ } -+#endif - return CompileCommandFile; - } -+ -+bool CompilerOracle::has_command_file() { -+ return cc_file() != NULL; -+} -+ - bool CompilerOracle::_quiet = false; - - void CompilerOracle::parse_from_file() { -+ assert(has_command_file(), "command file must be specified"); - FILE* stream = fopen(cc_file(), "rt"); - if (stream == NULL) return; - -@@ -600,6 +609,7 @@ - } - - void CompilerOracle::append_comment_to_file(const char* message) { -+ assert(has_command_file(), "command file must be specified"); - fileStream stream(fopen(cc_file(), "at")); - stream.print("# "); - for (int index = 0; message[index] != '\0'; index++) { -@@ -610,6 +620,7 @@ - } - - void CompilerOracle::append_exclude_to_file(methodHandle method) { -+ assert(has_command_file(), "command file must be specified"); - fileStream stream(fopen(cc_file(), "at")); - stream.print("exclude "); - Klass::cast(method->method_holder())->name()->print_symbol_on(&stream); -@@ -624,7 +635,9 @@ - void compilerOracle_init() { - CompilerOracle::parse_from_string(CompileCommand, CompilerOracle::parse_from_line); - CompilerOracle::parse_from_string(CompileOnly, CompilerOracle::parse_compile_only); -- CompilerOracle::parse_from_file(); -+ if (CompilerOracle::has_command_file()) { -+ CompilerOracle::parse_from_file(); -+ } - if (lists[PrintCommand] != NULL) { - if (PrintAssembly) { - warning("CompileCommand and/or .hotspot_compiler file contains 'print' commands, but PrintAssembly is also enabled"); -diff -r 149b6bbf77ff -r 6a7aac2ae8db src/share/vm/compiler/compilerOracle.hpp ---- hotspot/src/share/vm/compiler/compilerOracle.hpp Fri Mar 23 10:43:32 2012 -0700 -+++ hotspot/src/share/vm/compiler/compilerOracle.hpp Thu Mar 29 13:22:24 2012 -0400 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -36,6 +36,10 @@ - static bool _quiet; - - public: -+ -+ // True if the command file has been specified or is implicit -+ static bool has_command_file(); -+ - // Reads from file and adds to lists - static void parse_from_file(); - -diff -r 149b6bbf77ff -r 6a7aac2ae8db src/share/vm/opto/runtime.cpp ---- hotspot/src/share/vm/opto/runtime.cpp Fri Mar 23 10:43:32 2012 -0700 -+++ hotspot/src/share/vm/opto/runtime.cpp Thu Mar 29 13:22:24 2012 -0400 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -896,7 +896,8 @@ - methodOop method = ((nmethod*)n)->method(); - tty->print_cr("# Method where it happened %s.%s ", Klass::cast(method->method_holder())->name()->as_C_string(), method->name()->as_C_string()); - tty->print_cr("#"); -- if (ShowMessageBoxOnError && UpdateHotSpotCompilerFileOnError) { -+ if (ShowMessageBoxOnError && UpdateHotSpotCompilerFileOnError && -+ CompilerOracle::has_command_file()) { - const char* title = "HotSpot Runtime Error"; - const char* question = "Do you want to exclude compilation of this method in future runs?"; - if (os::message_box(title, question)) { -diff -r 149b6bbf77ff -r 6a7aac2ae8db src/share/vm/runtime/arguments.cpp ---- hotspot/src/share/vm/runtime/arguments.cpp Fri Mar 23 10:43:32 2012 -0700 -+++ hotspot/src/share/vm/runtime/arguments.cpp Thu Mar 29 13:22:24 2012 -0400 -@@ -2997,12 +2997,14 @@ - } - } - -+#ifdef ASSERT - // Parse default .hotspotrc settings file - if (!settings_file_specified) { - if (!process_settings_file(".hotspotrc", false, args->ignoreUnrecognized)) { - return JNI_EINVAL; - } - } -+#endif - - if (PrintVMOptions) { - for (index = 0; index < args->nOptions; index++) { -diff -r 149b6bbf77ff -r 6a7aac2ae8db test/runtime/7110720/Test7110720.sh ---- hotspot/test/runtime/7110720/Test7110720.sh Thu Jan 01 00:00:00 1970 +0000 -+++ hotspot/test/runtime/7110720/Test7110720.sh Thu Mar 29 13:22:24 2012 -0400 -@@ -0,0 +1,122 @@ -+# -+# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. -+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+# -+ -+ -+# -+# @test Test7110720.sh -+# @bug 7110720 -+# @summary improve VM configuration file loading -+# @run shell Test7110720.sh -+# -+ -+if [ "${TESTSRC}" = "" ] -+ then TESTSRC=. -+fi -+ -+if [ "${TESTJAVA}" = "" ] -+then -+ PARENT=`dirname \`which java\`` -+ TESTJAVA=`dirname ${PARENT}` -+ echo "TESTJAVA not set, selecting " ${TESTJAVA} -+ echo "If this is incorrect, try setting the variable manually." -+fi -+ -+if [ "${TESTCLASSES}" = "" ] -+then -+ echo "TESTCLASSES not set. Test cannot execute. Failed." -+ exit 1 -+fi -+ -+# Jtreg sets TESTVMOPTS which may include -d64 which is -+# required to test a 64-bit JVM on some platforms. -+# If another test harness still creates HOME/JDK64BIT, -+# we can recognise that. -+ -+# set platform-dependent variables -+OS=`uname -s` -+case "$OS" in -+ SunOS | Linux ) -+ FS="/" -+ RM=/bin/rm -+ CP=/bin/cp -+ MV=/bin/mv -+ ## for solaris, linux it's HOME -+ FILE_LOCATION=$HOME -+ if [ -f ${FILE_LOCATION}${FS}JDK64BIT -a ${OS} = "SunOS" ] -+ then -+ TESTVMOPTS=`cat ${FILE_LOCATION}${FS}JDK64BIT` -+ fi -+ ;; -+ Windows_* ) -+ FS="\\" -+ RM=rm -+ CP=cp -+ MV=mv -+ ;; -+ * ) -+ echo "Unrecognized system!" -+ exit 1; -+ ;; -+esac -+ -+ -+JAVA=${TESTJAVA}${FS}bin${FS}java -+ -+# Don't test debug builds, they do read the config files: -+${JAVA} ${TESTVMOPTS} -version 2>&1 | grep "debug" >/dev/null -+if [ "$?" = "0" ]; then -+ echo Skipping test for debug build. -+ exit 0 -+fi -+ -+ok=yes -+ -+$RM -f .hotspot_compiler .hotspotrc -+ -+${JAVA} ${TESTVMOPTS} -version 2>&1 | grep "garbage in" >/dev/null -+if [ "$?" = "0" ]; then -+ echo "FAILED: base case failure" -+ exit 1 -+fi -+ -+ -+echo "garbage in, garbage out" > .hotspot_compiler -+${JAVA} ${TESTVMOPTS} -version 2>&1 | grep "garbage in" >/dev/null -+if [ "$?" = "0" ]; then -+ echo "FAILED: .hotspot_compiler was read" -+ ok=no -+fi -+ -+$MV .hotspot_compiler hs_comp.txt -+${JAVA} ${TESTVMOPTS} -XX:CompileCommandFile=hs_comp.txt -version 2>&1 | grep "garbage in" >/dev/null -+if [ "$?" = "1" ]; then -+ echo "FAILED: explicit compiler command file not read" -+ ok=no -+fi -+ -+$RM -f .hotspot_compiler hs_comp.txt -+ -+echo "garbage" > .hotspotrc -+${JAVA} ${TESTVMOPTS} -version 2>&1 | grep "garbage" >/dev/null -+if [ "$?" = "0" ]; then -+ echo "FAILED: .hotspotrc was read" -+ ok=no -+fi -+ -+$MV .hotspotrc hs_flags.txt -+${JAVA} ${TESTVMOPTS} -XX:Flags=hs_flags.txt -version 2>&1 | grep "garbage" >/dev/null -+if [ "$?" = "1" ]; then -+ echo "FAILED: explicit flags file not read" -+ ok=no -+fi -+ -+if [ "${ok}" = "no" ]; then -+ echo "Some tests failed." -+ exit 1 -+else -+ echo "Passed" -+ exit 0 -+fi -+ -diff -r 988706e33b26 -r 21aac3eb7c40 src/macosx/classes/apple/applescript/AppleScriptEngine.java ---- jdk/src/macosx/classes/apple/applescript/AppleScriptEngine.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/macosx/classes/apple/applescript/AppleScriptEngine.java Tue Feb 28 15:44:47 2012 -0800 -@@ -26,6 +26,7 @@ - package apple.applescript; - - import java.io.*; -+import java.nio.file.Files; - import java.util.*; - import java.util.Map.Entry; - -@@ -297,7 +298,7 @@ - File tmpfile; - FileWriter tmpwrite; - try { -- tmpfile = File.createTempFile("AppleScriptEngine.", ".scpt"); -+ tmpfile = Files.createTempFile("AppleScriptEngine.", ".scpt").toFile(); - tmpwrite = new FileWriter(tmpfile); - - // read in our input and write directly to tmpfile -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/com/sun/java/util/jar/pack/Driver.java ---- jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java Tue Feb 28 15:44:47 2012 -0800 -@@ -35,6 +35,7 @@ - import java.io.OutputStream; - import java.io.PrintStream; - import java.text.MessageFormat; -+import java.nio.file.Files; - import java.util.ArrayList; - import java.util.Arrays; - import java.util.HashMap; -@@ -385,9 +386,7 @@ - if ( base.getParentFile() == null && suffix.equals(".bak")) - where = new File(".").getAbsoluteFile(); - -- -- File f = File.createTempFile(prefix, suffix, where); -- return f; -+ return Files.createTempFile(where.toPath(), prefix, suffix).toFile(); - } - - static private -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/java/awt/Font.java ---- jdk/src/share/classes/java/awt/Font.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/java/awt/Font.java Tue Feb 28 15:44:47 2012 -0800 -@@ -36,6 +36,7 @@ - import java.awt.peer.FontPeer; - import java.io.*; - import java.lang.ref.SoftReference; -+import java.nio.file.Files; - import java.security.AccessController; - import java.security.PrivilegedExceptionAction; - import java.text.AttributedCharacterIterator.Attribute; -@@ -830,7 +831,7 @@ - File f = null; - boolean hasPerm = false; - try { -- f = File.createTempFile("+~JT", ".tmp", null); -+ f = Files.createTempFile("+~JT", ".tmp").toFile(); - f.delete(); - f = null; - hasPerm = true; -@@ -880,7 +881,7 @@ - final File tFile = AccessController.doPrivileged( - new PrivilegedExceptionAction<File>() { - public File run() throws IOException { -- return File.createTempFile("+~JF", ".tmp", null); -+ return Files.createTempFile("+~JF", ".tmp").toFile(); - } - } - ); -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/javax/imageio/stream/FileCacheImageInputStream.java ---- jdk/src/share/classes/javax/imageio/stream/FileCacheImageInputStream.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/javax/imageio/stream/FileCacheImageInputStream.java Tue Feb 28 15:44:47 2012 -0800 -@@ -29,6 +29,7 @@ - import java.io.InputStream; - import java.io.IOException; - import java.io.RandomAccessFile; -+import java.nio.file.Files; - import com.sun.imageio.stream.StreamCloser; - import com.sun.imageio.stream.StreamFinalizer; - import sun.java2d.Disposer; -@@ -97,8 +98,11 @@ - throw new IllegalArgumentException("Not a directory!"); - } - this.stream = stream; -- this.cacheFile = -- File.createTempFile("imageio", ".tmp", cacheDir); -+ if (cacheDir == null) -+ this.cacheFile = Files.createTempFile("imageio", ".tmp").toFile(); -+ else -+ this.cacheFile = Files.createTempFile(cacheDir.toPath(), "imageio", ".tmp") -+ .toFile(); - this.cache = new RandomAccessFile(cacheFile, "rw"); - - this.closeAction = StreamCloser.createCloseAction(this); -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/javax/imageio/stream/FileCacheImageOutputStream.java ---- jdk/src/share/classes/javax/imageio/stream/FileCacheImageOutputStream.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/javax/imageio/stream/FileCacheImageOutputStream.java Tue Feb 28 15:44:47 2012 -0800 -@@ -29,6 +29,7 @@ - import java.io.IOException; - import java.io.OutputStream; - import java.io.RandomAccessFile; -+import java.nio.file.Files; - import com.sun.imageio.stream.StreamCloser; - - /** -@@ -83,8 +84,11 @@ - throw new IllegalArgumentException("Not a directory!"); - } - this.stream = stream; -- this.cacheFile = -- File.createTempFile("imageio", ".tmp", cacheDir); -+ if (cacheDir == null) -+ this.cacheFile = Files.createTempFile("imageio", ".tmp").toFile(); -+ else -+ this.cacheFile = Files.createTempFile(cacheDir.toPath(), "imageio", ".tmp") -+ .toFile(); - this.cache = new RandomAccessFile(cacheFile, "rw"); - - this.closeAction = StreamCloser.createCloseAction(this); -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/javax/management/loading/MLet.java ---- jdk/src/share/classes/javax/management/loading/MLet.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/javax/management/loading/MLet.java Tue Feb 28 15:44:47 2012 -0800 -@@ -44,6 +44,7 @@ - import java.net.MalformedURLException; - import java.net.URL; - import java.net.URLStreamHandlerFactory; -+import java.nio.file.Files; - import java.security.AccessController; - import java.security.PrivilegedAction; - import java.util.ArrayList; -@@ -1160,8 +1161,9 @@ - try { - File directory = new File(libraryDirectory); - directory.mkdirs(); -- File file = File.createTempFile(libname + ".", null, -- directory); -+ File file = Files.createTempFile(directory.toPath(), -+ libname + ".", null) -+ .toFile(); - file.deleteOnExit(); - FileOutputStream fileOutput = new FileOutputStream(file); - try { -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/sun/print/PSPrinterJob.java ---- jdk/src/share/classes/sun/print/PSPrinterJob.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/sun/print/PSPrinterJob.java Tue Feb 28 15:44:47 2012 -0800 -@@ -93,6 +93,7 @@ - import java.nio.charset.*; - import java.nio.CharBuffer; - import java.nio.ByteBuffer; -+import java.nio.file.Files; - - //REMIND: Remove use of this class when IPPPrintService is moved to share directory. - import java.lang.reflect.Method; -@@ -655,7 +656,7 @@ - * is not removed for some reason, request that it is - * removed when the VM exits. - */ -- spoolFile = File.createTempFile("javaprint", ".ps", null); -+ spoolFile = Files.createTempFile("javaprint", ".ps").toFile(); - spoolFile.deleteOnExit(); - - result = new FileOutputStream(spoolFile); -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/sun/rmi/server/Activation.java ---- jdk/src/share/classes/sun/rmi/server/Activation.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/sun/rmi/server/Activation.java Tue Feb 28 15:44:47 2012 -0800 -@@ -43,6 +43,7 @@ - import java.net.Socket; - import java.net.SocketAddress; - import java.net.SocketException; -+import java.nio.file.Files; - import java.nio.channels.Channel; - import java.nio.channels.ServerSocketChannel; - import java.rmi.AccessException; -@@ -1937,7 +1938,7 @@ - new PrivilegedExceptionAction<Void>() { - public Void run() throws IOException { - File file = -- File.createTempFile("rmid-err", null, null); -+ Files.createTempFile("rmid-err", null).toFile(); - PrintStream errStream = - new PrintStream(new FileOutputStream(file)); - System.setErr(errStream); -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/sun/tools/jar/Main.java ---- jdk/src/share/classes/sun/tools/jar/Main.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/sun/tools/jar/Main.java Tue Feb 28 15:44:47 2012 -0800 -@@ -137,7 +137,7 @@ - File dir = file.getParentFile(); - if (dir == null) - dir = new File("."); -- return File.createTempFile("jartmp", null, dir); -+ return Files.createTempFile(dir.toPath(), "jartmp", null).toFile(); - } - - private boolean ok; -diff -r 988706e33b26 -r 21aac3eb7c40 src/share/classes/sun/tools/native2ascii/Main.java ---- jdk/src/share/classes/sun/tools/native2ascii/Main.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/share/classes/sun/tools/native2ascii/Main.java Tue Feb 28 15:44:47 2012 -0800 -@@ -71,6 +71,7 @@ - import java.nio.charset.CharsetEncoder; - import java.nio.charset.Charset; - import java.nio.charset.IllegalCharsetNameException; -+import java.nio.file.Files; - import java.io.UnsupportedEncodingException; - import java.nio.charset.UnsupportedCharsetException; - import sun.tools.native2ascii.A2NFilter; -@@ -240,9 +241,7 @@ - if (tempDir == null) - tempDir = new File(System.getProperty("user.dir")); - -- tempFile = File.createTempFile("_N2A", -- ".TMP", -- tempDir); -+ tempFile = Files.createTempFile(tempDir.toPath(), "_N2A", ".TMP").toFile(); - tempFile.deleteOnExit(); - - try { -@@ -292,9 +291,7 @@ - File tempDir = f.getParentFile(); - if (tempDir == null) - tempDir = new File(System.getProperty("user.dir")); -- tempFile = File.createTempFile("_N2A", -- ".TMP", -- tempDir); -+ tempFile = Files.createTempFile(tempDir.toPath(), "_N2A", ".TMP").toFile(); - tempFile.deleteOnExit(); - - try { -diff -r 988706e33b26 -r 21aac3eb7c40 src/solaris/classes/sun/font/FcFontConfiguration.java ---- jdk/src/solaris/classes/sun/font/FcFontConfiguration.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/solaris/classes/sun/font/FcFontConfiguration.java Tue Feb 28 15:44:47 2012 -0800 -@@ -33,6 +33,7 @@ - import java.net.InetAddress; - import java.net.UnknownHostException; - import java.nio.charset.Charset; -+import java.nio.file.Files; - import java.util.HashMap; - import java.util.HashSet; - import java.util.Properties; -@@ -387,7 +388,7 @@ - File fcInfoFile = getFcInfoFile(); - File dir = fcInfoFile.getParentFile(); - dir.mkdirs(); -- File tempFile = File.createTempFile("fcinfo", null, dir); -+ File tempFile = Files.createTempFile(dir.toPath(), "fcinfo", null).toFile(); - FileOutputStream fos = new FileOutputStream(tempFile); - props.store(fos, - "JDK Font Configuration Generated File: *Do Not Edit*"); -diff -r 988706e33b26 -r 21aac3eb7c40 src/solaris/classes/sun/print/UnixPrintJob.java ---- jdk/src/solaris/classes/sun/print/UnixPrintJob.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/solaris/classes/sun/print/UnixPrintJob.java Tue Feb 28 15:44:47 2012 -0800 -@@ -40,6 +40,7 @@ - import java.io.IOException; - import java.io.Reader; - import java.io.UnsupportedEncodingException; -+import java.nio.file.Files; - import java.util.Vector; - - import javax.print.CancelablePrintJob; -@@ -936,7 +937,7 @@ - * is not removed for some reason, request that it is - * removed when the VM exits. - */ -- spoolFile = File.createTempFile("javaprint", ".ps", null); -+ spoolFile = Files.createTempFile("javaprint", ".ps").toFile(); - spoolFile.deleteOnExit(); - } - result = new FileOutputStream(spoolFile); -diff -r 988706e33b26 -r 21aac3eb7c40 src/solaris/classes/sun/print/UnixPrintServiceLookup.java ---- jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java Mon Feb 27 20:18:28 2012 +0200 -+++ jdk/src/solaris/classes/sun/print/UnixPrintServiceLookup.java Tue Feb 28 15:44:47 2012 -0800 -@@ -51,6 +51,7 @@ - import java.io.File; - import java.io.FileReader; - import java.net.URL; -+import java.nio.file.Files; - - /* - * Remind: This class uses solaris commands. We also need a linux -@@ -714,7 +715,7 @@ - - Process proc; - BufferedReader bufferedReader = null; -- File f = File.createTempFile("prn","xc"); -+ File f = Files.createTempFile("prn","xc").toFile(); - cmd[2] = cmd[2]+">"+f.getAbsolutePath(); - - proc = Runtime.getRuntime().exec(cmd); -diff -r 803475bf4582 -r 988706e33b26 src/share/classes/javax/swing/plaf/synth/SynthButtonUI.java ---- jdk/src/share/classes/javax/swing/plaf/synth/SynthButtonUI.java Fri Feb 24 10:25:55 2012 -0800 -+++ jdk/src/share/classes/javax/swing/plaf/synth/SynthButtonUI.java Mon Feb 27 20:18:28 2012 +0200 -@@ -152,8 +152,8 @@ - if (!c.isEnabled()) { - state = DISABLED; - } -- if (SynthLookAndFeel.selectedUI == this) { -- return SynthLookAndFeel.selectedUIState | SynthConstants.ENABLED; -+ if (SynthLookAndFeel.getSelectedUI() == this) { -+ return SynthLookAndFeel.getSelectedUIState() | SynthConstants.ENABLED; - } - AbstractButton button = (AbstractButton) c; - ButtonModel model = button.getModel(); -diff -r 803475bf4582 -r 988706e33b26 src/share/classes/javax/swing/plaf/synth/SynthLabelUI.java ---- jdk/src/share/classes/javax/swing/plaf/synth/SynthLabelUI.java Fri Feb 24 10:25:55 2012 -0800 -+++ jdk/src/share/classes/javax/swing/plaf/synth/SynthLabelUI.java Mon Feb 27 20:18:28 2012 +0200 -@@ -97,9 +97,9 @@ - - private int getComponentState(JComponent c) { - int state = SynthLookAndFeel.getComponentState(c); -- if (SynthLookAndFeel.selectedUI == this && -+ if (SynthLookAndFeel.getSelectedUI() == this && - state == SynthConstants.ENABLED) { -- state = SynthLookAndFeel.selectedUIState | SynthConstants.ENABLED; -+ state = SynthLookAndFeel.getSelectedUIState() | SynthConstants.ENABLED; - } - return state; - } -diff -r 803475bf4582 -r 988706e33b26 src/share/classes/javax/swing/plaf/synth/SynthLookAndFeel.java ---- jdk/src/share/classes/javax/swing/plaf/synth/SynthLookAndFeel.java Fri Feb 24 10:25:55 2012 -0800 -+++ jdk/src/share/classes/javax/swing/plaf/synth/SynthLookAndFeel.java Mon Feb 27 20:18:28 2012 +0200 -@@ -77,27 +77,25 @@ - new StringBuffer("com.sun.java.swing.plaf.gtk.StyleCache"); - - /** -+ * AppContext key to get selectedUI. -+ */ -+ private static final Object SELECTED_UI_KEY = new StringBuilder("selectedUI"); -+ -+ /** -+ * AppContext key to get selectedUIState. -+ */ -+ private static final Object SELECTED_UI_STATE_KEY = new StringBuilder("selectedUIState"); -+ -+ /** - * The last SynthStyleFactory that was asked for from AppContext - * <code>lastContext</code>. - */ - private static SynthStyleFactory lastFactory; - /** -- * If this is true it indicates there is more than one AppContext active -- * and that we need to make sure in getStyleCache the requesting -- * AppContext matches that of <code>lastContext</code> before returning -- * it. -- */ -- private static boolean multipleApps; -- /** - * AppContext lastLAF came from. - */ - private static AppContext lastContext; - -- // Refer to setSelectedUI -- static ComponentUI selectedUI; -- // Refer to setSelectedUI -- static int selectedUIState; -- - /** - * SynthStyleFactory for the this SynthLookAndFeel. - */ -@@ -111,6 +109,10 @@ - - private Handler _handler; - -+ static ComponentUI getSelectedUI() { -+ return (ComponentUI) AppContext.getAppContext().get(SELECTED_UI_KEY); -+ } -+ - /** - * Used by the renderers. For the most part the renderers are implemented - * as Labels, which is problematic in so far as they are never selected. -@@ -122,8 +124,8 @@ - static void setSelectedUI(ComponentUI uix, boolean selected, - boolean focused, boolean enabled, - boolean rollover) { -- selectedUI = uix; -- selectedUIState = 0; -+ int selectedUIState = 0; -+ - if (selected) { - selectedUIState = SynthConstants.SELECTED; - if (focused) { -@@ -140,19 +142,32 @@ - else { - if (enabled) { - selectedUIState |= SynthConstants.ENABLED; -- selectedUIState = SynthConstants.FOCUSED; -+ if (focused) { -+ selectedUIState |= SynthConstants.FOCUSED; -+ } - } - else { - selectedUIState |= SynthConstants.DISABLED; - } - } -+ -+ AppContext context = AppContext.getAppContext(); -+ -+ context.put(SELECTED_UI_KEY, uix); -+ context.put(SELECTED_UI_STATE_KEY, Integer.valueOf(selectedUIState)); -+ } -+ -+ static int getSelectedUIState() { -+ Integer result = (Integer) AppContext.getAppContext().get(SELECTED_UI_STATE_KEY); -+ -+ return result == null ? 0 : result.intValue(); - } - - /** - * Clears out the selected UI that was last set in setSelectedUI. - */ - static void resetSelectedUI() { -- selectedUI = null; -+ AppContext.getAppContext().remove(SELECTED_UI_KEY); - } - - -@@ -167,10 +182,6 @@ - // for a particular AppContext. - synchronized(SynthLookAndFeel.class) { - AppContext context = AppContext.getAppContext(); -- if (!multipleApps && context != lastContext && -- lastContext != null) { -- multipleApps = true; -- } - lastFactory = cache; - lastContext = context; - context.put(STYLE_FACTORY_KEY, cache); -@@ -184,17 +195,13 @@ - */ - public static SynthStyleFactory getStyleFactory() { - synchronized(SynthLookAndFeel.class) { -- if (!multipleApps) { -- return lastFactory; -- } - AppContext context = AppContext.getAppContext(); - - if (lastContext == context) { - return lastFactory; - } - lastContext = context; -- lastFactory = (SynthStyleFactory)AppContext.getAppContext().get -- (STYLE_FACTORY_KEY); -+ lastFactory = (SynthStyleFactory) context.get(STYLE_FACTORY_KEY); - return lastFactory; - } - } -diff -r 803475bf4582 -r 988706e33b26 test/javax/swing/plaf/synth/7143614/bug7143614.java ---- jdk/test/javax/swing/plaf/synth/7143614/bug7143614.java Thu Jan 01 00:00:00 1970 +0000 -+++ jdk/test/javax/swing/plaf/synth/7143614/bug7143614.java Mon Feb 27 20:18:28 2012 +0200 -@@ -0,0 +1,97 @@ -+/* -+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. -+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+ * -+ * This code is free software; you can redistribute it and/or modify it -+ * under the terms of the GNU General Public License version 2 only, as -+ * published by the Free Software Foundation. -+ * -+ * This code is distributed in the hope that it will be useful, but WITHOUT -+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -+ * version 2 for more details (a copy is included in the LICENSE file that -+ * accompanied this code). -+ * -+ * You should have received a copy of the GNU General Public License version -+ * 2 along with this work; if not, write to the Free Software Foundation, -+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -+ * -+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -+ * or visit www.oracle.com if you need additional information or have any -+ * questions. -+ */ -+ -+/* -+ * @test -+ * @bug 7143614 -+ * @summary Issues with Synth Look&Feel -+ * @author Pavel Porvatov -+ */ -+ -+import sun.awt.SunToolkit; -+ -+import javax.swing.plaf.ComponentUI; -+import javax.swing.plaf.basic.BasicButtonUI; -+import javax.swing.plaf.synth.SynthConstants; -+import javax.swing.plaf.synth.SynthLookAndFeel; -+import java.lang.reflect.Method; -+ -+public class bug7143614 { -+ private static Method setSelectedUIMethod; -+ -+ private static ComponentUI componentUI = new BasicButtonUI(); -+ -+ public static void main(String[] args) throws Exception { -+ setSelectedUIMethod = SynthLookAndFeel.class.getDeclaredMethod("setSelectedUI", ComponentUI.class, -+ boolean.class, boolean.class, boolean.class, boolean.class); -+ setSelectedUIMethod.setAccessible(true); -+ -+ setSelectedUIMethod.invoke(null, componentUI, true, true, true, true); -+ -+ validate(); -+ -+ Thread thread = new ThreadInAnotherAppContext(); -+ -+ thread.start(); -+ thread.join(); -+ -+ validate(); -+ -+ System.out.println("Test bug7143614 passed."); -+ } -+ -+ private static void validate() throws Exception { -+ Method getSelectedUIMethod = SynthLookAndFeel.class.getDeclaredMethod("getSelectedUI"); -+ -+ getSelectedUIMethod.setAccessible(true); -+ -+ Method getSelectedUIStateMethod = SynthLookAndFeel.class.getDeclaredMethod("getSelectedUIState"); -+ -+ getSelectedUIStateMethod.setAccessible(true); -+ -+ if (getSelectedUIMethod.invoke(null) != componentUI) { -+ throw new RuntimeException("getSelectedUI returns invalid value"); -+ } -+ if (((Integer) getSelectedUIStateMethod.invoke(null)).intValue() != -+ (SynthConstants.SELECTED | SynthConstants.FOCUSED)) { -+ throw new RuntimeException("getSelectedUIState returns invalid value"); -+ } -+ -+ } -+ -+ private static class ThreadInAnotherAppContext extends Thread { -+ public ThreadInAnotherAppContext() { -+ super(new ThreadGroup("7143614"), "ThreadInAnotherAppContext"); -+ } -+ -+ public void run() { -+ SunToolkit.createNewAppContext(); -+ -+ try { -+ setSelectedUIMethod.invoke(null, null, false, false, false, false); -+ } catch (Exception e) { -+ throw new RuntimeException(e); -+ } -+ } -+ } -+} -diff -r d568e85567cc -r eb3da9b13e3c src/share/native/sun/font/layout/LookupProcessor.cpp ---- jdk/src/share/native/sun/font/layout/LookupProcessor.cpp Mon Feb 06 17:10:46 2012 -0800 -+++ jdk/src/share/native/sun/font/layout/LookupProcessor.cpp Wed Feb 15 10:59:12 2012 +0400 -@@ -95,6 +95,10 @@ - - if (selectMask != 0) { - const LookupTable *lookupTable = lookupListTable->getLookupTable(lookup); -+ -+ if (!lookupTable) -+ continue; -+ - le_uint16 lookupFlags = SWAPW(lookupTable->lookupFlags); - - glyphIterator.reset(lookupFlags, selectMask); -@@ -136,6 +140,9 @@ - for (le_uint16 lookup = 0; lookup < lookupCount; lookup += 1) { - le_uint16 lookupListIndex = SWAPW(featureTable->lookupListIndexArray[lookup]); - -+ if (lookupListIndex >= lookupSelectCount) -+ continue; -+ - lookupSelectArray[lookupListIndex] |= featureMask; - lookupOrderArray[store++] = lookupListIndex; - } -@@ -147,7 +154,7 @@ - Offset scriptListOffset, Offset featureListOffset, Offset lookupListOffset, - LETag scriptTag, LETag languageTag, const FeatureMap *featureMap, le_int32 featureMapCount, le_bool orderFeatures, - LEErrorCode& success) -- : lookupListTable(NULL), featureListTable(NULL), lookupSelectArray(NULL), -+ : lookupListTable(NULL), featureListTable(NULL), lookupSelectArray(NULL), lookupSelectCount(0), - lookupOrderArray(NULL), lookupOrderCount(0) - { - const ScriptListTable *scriptListTable = NULL; -@@ -195,6 +202,8 @@ - lookupSelectArray[i] = 0; - } - -+ lookupSelectCount = lookupListCount; -+ - le_int32 count, order = 0; - le_int32 featureReferences = 0; - const FeatureTable *featureTable = NULL; -@@ -211,6 +220,10 @@ - le_uint16 featureIndex = SWAPW(langSysTable->featureIndexArray[feature]); - - featureTable = featureListTable->getFeatureTable(featureIndex, &featureTag); -+ -+ if (!featureTable) -+ continue; -+ - featureReferences += SWAPW(featureTable->lookupCount); - } - -diff -r d568e85567cc -r eb3da9b13e3c src/share/native/sun/font/layout/LookupProcessor.h ---- jdk/src/share/native/sun/font/layout/LookupProcessor.h Mon Feb 06 17:10:46 2012 -0800 -+++ jdk/src/share/native/sun/font/layout/LookupProcessor.h Wed Feb 15 10:59:12 2012 +0400 -@@ -90,6 +90,7 @@ - const FeatureListTable *featureListTable; - - FeatureMask *lookupSelectArray; -+ le_uint32 lookupSelectCount; - - le_uint16 *lookupOrderArray; - le_uint32 lookupOrderCount; -diff -r 2e5e8c37d787 -r b5eacf258d78 src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java ---- corba/src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java Tue Feb 28 17:00:14 2012 +0000 -+++ corba/src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java Wed Feb 29 16:41:49 2012 +0000 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1998, 2007, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -425,7 +425,7 @@ - // Write the _ids() method... - - p.plnI("public String[] _ids() { "); -- p.pln("return _type_ids;"); -+ p.pln("return (String[]) _type_ids.clone();"); - p.pOln("}"); - - // Get all the methods and write each stub method... -@@ -1860,11 +1860,11 @@ - { - if(POATie){ - p.plnI("public String[] _all_interfaces(org.omg.PortableServer.POA poa, byte[] objectId){"); -- p.pln("return _type_ids;"); -+ p.pln("return (String[]) _type_ids.clone();"); - p.pOln("}"); - } else { - p.plnI("public String[] _ids() { "); -- p.pln("return _type_ids;"); -+ p.pln("return (String[]) _type_ids.clone();"); - p.pOln("}"); - } - } -diff -r 5fc4da84eff8 -r 4b0c75c7ce73 make/com/sun/jmx/Makefile ---- jdk/make/com/sun/jmx/Makefile Wed Feb 29 14:06:00 2012 +0800 -+++ jdk/make/com/sun/jmx/Makefile Wed Feb 29 16:48:03 2012 +0000 -@@ -1,5 +1,5 @@ - # --# Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. -+# Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. - # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - # - # This code is free software; you can redistribute it and/or modify it -@@ -100,6 +100,23 @@ - # so that *_tie classes are generated in package without the prefix - # org.omg.stub (6375696) - # -+# To ensure the latest stub generator files are picked up from corba repo -+# when available, we need to run with latest rmic version available. rmic -+# launch tool not built at this stage but we can invoke via rmi class. -+ -+RMIC_JAVA = $(OUTPUTDIR)/bin/java -+# need to treat 64bit solaris differently -+ifeq ($(PLATFORM)-$(LIBARCH), solaris-amd64) -+RMIC_JAVA = $(OUTPUTDIR)/bin/amd64/java -+endif -+ifeq ($(PLATFORM)-$(LIBARCH), solaris-sparcv9) -+RMIC_JAVA = $(OUTPUTDIR)/bin/sparcv9/java -+endif -+ -+ifeq ($(CROSS_COMPILE_ARCH),) -+RMIC = $(RMIC_JAVA) $(JAVA_TOOLS_FLAGS) -cp $(OUTPUTDIR)/classes sun.rmi.rmic.Main -+endif -+ - $(CLASSDESTDIR)/%_Stub.class: $(CLASSDESTDIR)/%.class - $(prep-target) - $(RMIC) -classpath "$(CLASSDESTDIR)" \ -diff -r 21aac3eb7c40 -r 5fc4da84eff8 src/share/classes/sun/security/x509/CRLExtensions.java ---- jdk/src/share/classes/sun/security/x509/CRLExtensions.java Tue Feb 28 15:44:47 2012 -0800 -+++ jdk/src/share/classes/sun/security/x509/CRLExtensions.java Wed Feb 29 14:06:00 2012 +0800 -@@ -32,8 +32,10 @@ - import java.security.cert.CRLException; - import java.security.cert.CertificateException; - import java.util.Collection; -+import java.util.Collections; - import java.util.Enumeration; --import java.util.Hashtable; -+import java.util.Map; -+import java.util.TreeMap; - - import sun.security.util.*; - import sun.misc.HexDumpEncoder; -@@ -62,7 +64,8 @@ - */ - public class CRLExtensions { - -- private Hashtable<String,Extension> map = new Hashtable<String,Extension>(); -+ private Map<String,Extension> map = Collections.synchronizedMap( -+ new TreeMap<String,Extension>()); - private boolean unsupportedCritExt = false; - - /** -@@ -215,7 +218,7 @@ - * @return an enumeration of the extensions in this CRL. - */ - public Enumeration<Extension> getElements() { -- return map.elements(); -+ return Collections.enumeration(map.values()); - } - - /** -diff -r 21aac3eb7c40 -r 5fc4da84eff8 src/share/classes/sun/security/x509/CertificateExtensions.java ---- jdk/src/share/classes/sun/security/x509/CertificateExtensions.java Tue Feb 28 15:44:47 2012 -0800 -+++ jdk/src/share/classes/sun/security/x509/CertificateExtensions.java Wed Feb 29 14:06:00 2012 +0800 -@@ -57,7 +57,8 @@ - - private static final Debug debug = Debug.getInstance("x509"); - -- private Hashtable<String,Extension> map = new Hashtable<String,Extension>(); -+ private Map<String,Extension> map = Collections.synchronizedMap( -+ new TreeMap<String,Extension>()); - private boolean unsupportedCritExt = false; - - private Map<String,Extension> unparseableExtensions; -@@ -117,7 +118,7 @@ - if (ext.isCritical() == false) { - // ignore errors parsing non-critical extensions - if (unparseableExtensions == null) { -- unparseableExtensions = new HashMap<String,Extension>(); -+ unparseableExtensions = new TreeMap<String,Extension>(); - } - unparseableExtensions.put(ext.getExtensionId().toString(), - new UnparseableExtension(ext, e)); -@@ -218,6 +219,12 @@ - return (obj); - } - -+ // Similar to get(String), but throw no exception, might return null. -+ // Used in X509CertImpl::getExtension(OID). -+ Extension getExtension(String name) { -+ return map.get(name); -+ } -+ - /** - * Delete the attribute value. - * @param name the extension name used in the lookup. -@@ -245,7 +252,7 @@ - * attribute. - */ - public Enumeration<Extension> getElements() { -- return map.elements(); -+ return Collections.enumeration(map.values()); - } - - /** -diff -r 21aac3eb7c40 -r 5fc4da84eff8 src/share/classes/sun/security/x509/X509CRLEntryImpl.java ---- jdk/src/share/classes/sun/security/x509/X509CRLEntryImpl.java Tue Feb 28 15:44:47 2012 -0800 -+++ jdk/src/share/classes/sun/security/x509/X509CRLEntryImpl.java Wed Feb 29 14:06:00 2012 +0800 -@@ -32,13 +32,7 @@ - import java.security.cert.CertificateException; - import java.security.cert.X509CRLEntry; - import java.math.BigInteger; --import java.util.Collection; --import java.util.Date; --import java.util.Enumeration; --import java.util.HashMap; --import java.util.Map; --import java.util.Set; --import java.util.HashSet; -+import java.util.*; - - import javax.security.auth.x500.X500Principal; - -@@ -75,7 +69,8 @@ - * @author Hemma Prafullchandra - */ - --public class X509CRLEntryImpl extends X509CRLEntry { -+public class X509CRLEntryImpl extends X509CRLEntry -+ implements Comparable<X509CRLEntryImpl> { - - private SerialNumber serialNumber = null; - private Date revocationDate = null; -@@ -196,9 +191,14 @@ - * @exception CRLException if an encoding error occurs. - */ - public byte[] getEncoded() throws CRLException { -+ return getEncoded0().clone(); -+ } -+ -+ // Called internally to avoid clone -+ private byte[] getEncoded0() throws CRLException { - if (revokedCert == null) - this.encode(new DerOutputStream()); -- return revokedCert.clone(); -+ return revokedCert; - } - - @Override -@@ -352,7 +352,7 @@ - if (extensions == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : extensions.getAllExtensions()) { - if (ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -373,7 +373,7 @@ - if (extensions == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : extensions.getAllExtensions()) { - if (!ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -501,13 +501,39 @@ - getExtension(PKIXExtensions.CertificateIssuer_Id); - } - -+ /** -+ * Returns all extensions for this entry in a map -+ * @return the extension map, can be empty, but not null -+ */ - public Map<String, java.security.cert.Extension> getExtensions() { -+ if (extensions == null) { -+ return Collections.emptyMap(); -+ } - Collection<Extension> exts = extensions.getAllExtensions(); -- HashMap<String, java.security.cert.Extension> map = -- new HashMap<String, java.security.cert.Extension>(exts.size()); -+ Map<String, java.security.cert.Extension> map = new TreeMap<>(); - for (Extension ext : exts) { - map.put(ext.getId(), ext); - } - return map; - } -+ -+ @Override -+ public int compareTo(X509CRLEntryImpl that) { -+ int compSerial = getSerialNumber().compareTo(that.getSerialNumber()); -+ if (compSerial != 0) { -+ return compSerial; -+ } -+ try { -+ byte[] thisEncoded = this.getEncoded0(); -+ byte[] thatEncoded = that.getEncoded0(); -+ for (int i=0; i<thisEncoded.length && i<thatEncoded.length; i++) { -+ int a = thisEncoded[i] & 0xff; -+ int b = thatEncoded[i] & 0xff; -+ if (a != b) return a-b; -+ } -+ return thisEncoded.length -thatEncoded.length; -+ } catch (CRLException ce) { -+ return -1; -+ } -+ } - } -diff -r 21aac3eb7c40 -r 5fc4da84eff8 src/share/classes/sun/security/x509/X509CRLImpl.java ---- jdk/src/share/classes/sun/security/x509/X509CRLImpl.java Tue Feb 28 15:44:47 2012 -0800 -+++ jdk/src/share/classes/sun/security/x509/X509CRLImpl.java Wed Feb 29 14:06:00 2012 +0800 -@@ -53,7 +53,7 @@ - - /** - * <p> -- * An implmentation for X509 CRL (Certificate Revocation List). -+ * An implementation for X509 CRL (Certificate Revocation List). - * <p> - * The X.509 v2 CRL format is described below in ASN.1: - * <pre> -@@ -104,7 +104,8 @@ - private X500Principal issuerPrincipal = null; - private Date thisUpdate = null; - private Date nextUpdate = null; -- private Map<X509IssuerSerial,X509CRLEntry> revokedCerts = new LinkedHashMap<X509IssuerSerial,X509CRLEntry>(); -+ private Map<X509IssuerSerial,X509CRLEntry> revokedMap = new TreeMap<>(); -+ private List<X509CRLEntry> revokedList = new LinkedList<>(); - private CRLExtensions extensions = null; - private final static boolean isExplicit = true; - private static final long YR_2050 = 2524636800000L; -@@ -223,7 +224,8 @@ - badCert.setCertificateIssuer(crlIssuer, badCertIssuer); - X509IssuerSerial issuerSerial = new X509IssuerSerial - (badCertIssuer, badCert.getSerialNumber()); -- this.revokedCerts.put(issuerSerial, badCert); -+ this.revokedMap.put(issuerSerial, badCert); -+ this.revokedList.add(badCert); - if (badCert.hasExtensions()) { - this.version = 1; - } -@@ -305,8 +307,8 @@ - tmp.putGeneralizedTime(nextUpdate); - } - -- if (!revokedCerts.isEmpty()) { -- for (X509CRLEntry entry : revokedCerts.values()) { -+ if (!revokedList.isEmpty()) { -+ for (X509CRLEntry entry : revokedList) { - ((X509CRLEntryImpl)entry).encode(rCerts); - } - tmp.write(DerValue.tag_Sequence, rCerts); -@@ -490,14 +492,14 @@ - sb.append("\nThis Update: " + thisUpdate.toString() + "\n"); - if (nextUpdate != null) - sb.append("Next Update: " + nextUpdate.toString() + "\n"); -- if (revokedCerts.isEmpty()) -+ if (revokedList.isEmpty()) - sb.append("\nNO certificates have been revoked\n"); - else { -- sb.append("\nRevoked Certificates: " + revokedCerts.size()); -+ sb.append("\nRevoked Certificates: " + revokedList.size()); - int i = 1; -- for (Iterator<X509CRLEntry> iter = revokedCerts.values().iterator(); -- iter.hasNext(); i++) -- sb.append("\n[" + i + "] " + iter.next().toString()); -+ for (X509CRLEntry entry: revokedList) { -+ sb.append("\n[" + i++ + "] " + entry.toString()); -+ } - } - if (extensions != null) { - Collection<Extension> allExts = extensions.getAllExtensions(); -@@ -543,12 +545,12 @@ - * false otherwise. - */ - public boolean isRevoked(Certificate cert) { -- if (revokedCerts.isEmpty() || (!(cert instanceof X509Certificate))) { -+ if (revokedMap.isEmpty() || (!(cert instanceof X509Certificate))) { - return false; - } - X509Certificate xcert = (X509Certificate) cert; - X509IssuerSerial issuerSerial = new X509IssuerSerial(xcert); -- return revokedCerts.containsKey(issuerSerial); -+ return revokedMap.containsKey(issuerSerial); - } - - /** -@@ -638,24 +640,24 @@ - * @see X509CRLEntry - */ - public X509CRLEntry getRevokedCertificate(BigInteger serialNumber) { -- if (revokedCerts.isEmpty()) { -+ if (revokedMap.isEmpty()) { - return null; - } - // assume this is a direct CRL entry (cert and CRL issuer are the same) - X509IssuerSerial issuerSerial = new X509IssuerSerial - (getIssuerX500Principal(), serialNumber); -- return revokedCerts.get(issuerSerial); -+ return revokedMap.get(issuerSerial); - } - - /** - * Gets the CRL entry for the given certificate. - */ - public X509CRLEntry getRevokedCertificate(X509Certificate cert) { -- if (revokedCerts.isEmpty()) { -+ if (revokedMap.isEmpty()) { - return null; - } - X509IssuerSerial issuerSerial = new X509IssuerSerial(cert); -- return revokedCerts.get(issuerSerial); -+ return revokedMap.get(issuerSerial); - } - - /** -@@ -667,10 +669,10 @@ - * @see X509CRLEntry - */ - public Set<X509CRLEntry> getRevokedCertificates() { -- if (revokedCerts.isEmpty()) { -+ if (revokedList.isEmpty()) { - return null; - } else { -- return new HashSet<X509CRLEntry>(revokedCerts.values()); -+ return new TreeSet<X509CRLEntry>(revokedList); - } - } - -@@ -905,7 +907,7 @@ - if (extensions == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : extensions.getAllExtensions()) { - if (ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -926,7 +928,7 @@ - if (extensions == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : extensions.getAllExtensions()) { - if (!ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -1103,7 +1105,8 @@ - entry.setCertificateIssuer(crlIssuer, badCertIssuer); - X509IssuerSerial issuerSerial = new X509IssuerSerial - (badCertIssuer, entry.getSerialNumber()); -- revokedCerts.put(issuerSerial, entry); -+ revokedMap.put(issuerSerial, entry); -+ revokedList.add(entry); - } - } - -@@ -1208,7 +1211,8 @@ - /** - * Immutable X.509 Certificate Issuer DN and serial number pair - */ -- private final static class X509IssuerSerial { -+ private final static class X509IssuerSerial -+ implements Comparable<X509IssuerSerial> { - final X500Principal issuer; - final BigInteger serial; - volatile int hashcode = 0; -@@ -1287,5 +1291,13 @@ - } - return hashcode; - } -+ -+ @Override -+ public int compareTo(X509IssuerSerial another) { -+ int cissuer = issuer.toString() -+ .compareTo(another.issuer.toString()); -+ if (cissuer != 0) return cissuer; -+ return this.serial.compareTo(another.serial); -+ } - } - } -diff -r 21aac3eb7c40 -r 5fc4da84eff8 src/share/classes/sun/security/x509/X509CertImpl.java ---- jdk/src/share/classes/sun/security/x509/X509CertImpl.java Tue Feb 28 15:44:47 2012 -0800 -+++ jdk/src/share/classes/sun/security/x509/X509CertImpl.java Wed Feb 29 14:06:00 2012 +0800 -@@ -1214,7 +1214,7 @@ - if (exts == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : exts.getAllExtensions()) { - if (ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -1244,7 +1244,7 @@ - if (exts == null) { - return null; - } -- Set<String> extSet = new HashSet<String>(); -+ Set<String> extSet = new TreeSet<>(); - for (Extension ex : exts.getAllExtensions()) { - if (!ex.isCritical()) { - extSet.add(ex.getExtensionId().toString()); -@@ -1278,10 +1278,14 @@ - if (extensions == null) { - return null; - } else { -- for (Extension ex : extensions.getAllExtensions()) { -- if (ex.getExtensionId().equals(oid)) { -+ Extension ex = extensions.getExtension(oid.toString()); -+ if (ex != null) { -+ return ex; -+ } -+ for (Extension ex2: extensions.getAllExtensions()) { -+ if (ex2.getExtensionId().equals((Object)oid)) { - //XXXX May want to consider cloning this -- return ex; -+ return ex2; - } - } - /* no such extension in this certificate */ -@@ -1480,10 +1484,10 @@ - if (names.isEmpty()) { - return Collections.<List<?>>emptySet(); - } -- Set<List<?>> newNames = new HashSet<List<?>>(); -+ List<List<?>> newNames = new ArrayList<>(); - for (GeneralName gname : names.names()) { - GeneralNameInterface name = gname.getName(); -- List<Object> nameEntry = new ArrayList<Object>(2); -+ List<Object> nameEntry = new ArrayList<>(2); - nameEntry.add(Integer.valueOf(name.getType())); - switch (name.getType()) { - case GeneralNameInterface.NAME_RFC822: -@@ -1541,12 +1545,12 @@ - } - } - if (mustClone) { -- Set<List<?>> namesCopy = new HashSet<List<?>>(); -+ List<List<?>> namesCopy = new ArrayList<>(); - for (List<?> nameEntry : altNames) { - Object nameObject = nameEntry.get(1); - if (nameObject instanceof byte[]) { - List<Object> nameEntryCopy = -- new ArrayList<Object>(nameEntry); -+ new ArrayList<>(nameEntry); - nameEntryCopy.set(1, ((byte[])nameObject).clone()); - namesCopy.add(Collections.unmodifiableList(nameEntryCopy)); - } else { -diff -r 21aac3eb7c40 -r 5fc4da84eff8 test/sun/security/x509/X509CRLImpl/OrderAndDup.java ---- jdk/test/sun/security/x509/X509CRLImpl/OrderAndDup.java Thu Jan 01 00:00:00 1970 +0000 -+++ jdk/test/sun/security/x509/X509CRLImpl/OrderAndDup.java Wed Feb 29 14:06:00 2012 +0800 -@@ -0,0 +1,99 @@ -+/* -+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. -+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+ * -+ * This code is free software; you can redistribute it and/or modify it -+ * under the terms of the GNU General Public License version 2 only, as -+ * published by the Free Software Foundation. -+ * -+ * This code is distributed in the hope that it will be useful, but WITHOUT -+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -+ * version 2 for more details (a copy is included in the LICENSE file that -+ * accompanied this code). -+ * -+ * You should have received a copy of the GNU General Public License version -+ * 2 along with this work; if not, write to the Free Software Foundation, -+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -+ * -+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -+ * or visit www.oracle.com if you need additional information or have any -+ * questions. -+ */ -+ -+/* -+ * @test -+ * @bug 7143872 -+ * @summary Improve certificate extension processing -+ */ -+import java.io.ByteArrayInputStream; -+import java.math.BigInteger; -+import java.security.KeyPairGenerator; -+import java.security.cert.CertificateFactory; -+import java.security.cert.X509CRLEntry; -+import java.util.Date; -+import sun.security.util.DerInputStream; -+import sun.security.util.DerValue; -+import sun.security.x509.*; -+ -+public class OrderAndDup { -+ public static void main(String[] args) throws Exception { -+ -+ // Generate 20 serial numbers with dup and a special order -+ int count = 20; -+ BigInteger[] serials = new BigInteger[count]; -+ for (int i=0; i<count; i++) { -+ serials[i] = BigInteger.valueOf(i*7%10); -+ } -+ -+ // Generates a CRL -+ X509CRLEntry[] badCerts = new X509CRLEntry[count]; -+ for (int i=0; i<count; i++) { -+ badCerts[i] = new X509CRLEntryImpl(serials[i], -+ new Date(System.currentTimeMillis()+i*1000)); -+ } -+ X500Name owner = new X500Name("CN=CA"); -+ X509CRLImpl crl = new X509CRLImpl(owner, new Date(), new Date(), badCerts); -+ KeyPairGenerator kpg = KeyPairGenerator.getInstance("RSA"); -+ crl.sign(kpg.genKeyPair().getPrivate(), "SHA1withRSA"); -+ byte[] data = crl.getEncodedInternal(); -+ -+ // Check the encoding -+ checkData(crl, data, serials); -+ -+ // Load a CRL from raw data -+ CertificateFactory cf = CertificateFactory.getInstance("X.509"); -+ X509CRLImpl crl2 = (X509CRLImpl)cf.generateCRL(new ByteArrayInputStream(data)); -+ -+ // Check the encoding again -+ data = crl2.getEncodedInternal(); -+ checkData(crl2, data, serials); -+ } -+ -+ // Check the raw data's ASN.1 structure to see if the revoked certs -+ // have the same number and correct order as inserted -+ static void checkData(X509CRLImpl c, byte[] data, BigInteger[] expected) -+ throws Exception { -+ if (c.getRevokedCertificates().size() != expected.length) { -+ throw new Exception("Wrong count in CRL object, now " + -+ c.getRevokedCertificates().size()); -+ } -+ DerValue d1 = new DerValue(data); -+ // revokedCertificates at 5th place of TBSCertList -+ DerValue[] d2 = new DerInputStream( -+ d1.data.getSequence(0)[4].toByteArray()) -+ .getSequence(0); -+ if (d2.length != expected.length) { -+ throw new Exception("Wrong count in raw data, now " + d2.length); -+ } -+ for (int i=0; i<d2.length; i++) { -+ // Serial is first in revokedCertificates entry -+ BigInteger bi = d2[i].data.getBigInteger(); -+ if (!bi.equals(expected[i])) { -+ throw new Exception("Entry at #" + i + " is " + bi -+ + ", should be " + expected[i]); -+ } -+ } -+ } -+} -+ -diff -r d568e85567cc -r 1338c556c39b src/share/lib/security/java.security ---- jdk/src/share/lib/security/java.security Mon Feb 06 17:10:46 2012 -0800 -+++ jdk/src/share/lib/security/java.security Wed Feb 22 08:14:48 2012 -0500 -@@ -123,7 +123,7 @@ - # passed to checkPackageAccess unless the - # corresponding RuntimePermission ("accessClassInPackage."+package) has - # been granted. --package.access=sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils. -+package.access=sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils. - - # - # List of comma-separated packages that start with or equal this string -@@ -132,10 +132,10 @@ - # corresponding RuntimePermission ("defineClassInPackage."+package) has - # been granted. - # --# by default, no packages are restricted for definition, and none of --# the class loaders supplied with the JDK call checkPackageDefinition. -+# by default, none of the class loaders supplied with the JDK call -+# checkPackageDefinition. - # --#package.definition= -+package.definition=sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils. - - # - # Determines whether this properties file can be appended to -diff -r d568e85567cc -r 1338c556c39b src/share/lib/security/java.security-macosx ---- jdk/src/share/lib/security/java.security-macosx Mon Feb 06 17:10:46 2012 -0800 -+++ jdk/src/share/lib/security/java.security-macosx Wed Feb 22 08:14:48 2012 -0500 -@@ -133,10 +133,10 @@ - # corresponding RuntimePermission ("defineClassInPackage."+package) has - # been granted. - # --# by default, no packages are restricted for definition, and none of --# the class loaders supplied with the JDK call checkPackageDefinition. -+# by default, none of the class loaders supplied with the JDK call -+# checkPackageDefinition. - # --#package.definition= -+package.definition=sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils.,apple. - - # - # Determines whether this properties file can be appended to -diff -r d568e85567cc -r 1338c556c39b src/share/lib/security/java.security-solaris ---- jdk/src/share/lib/security/java.security-solaris Mon Feb 06 17:10:46 2012 -0800 -+++ jdk/src/share/lib/security/java.security-solaris Wed Feb 22 08:14:48 2012 -0500 -@@ -134,10 +134,10 @@ - # corresponding RuntimePermission ("defineClassInPackage."+package) has - # been granted. - # --# by default, no packages are restricted for definition, and none of --# the class loaders supplied with the JDK call checkPackageDefinition. -+# by default, none of the class loaders supplied with the JDK call -+# checkPackageDefinition. - # --#package.definition= -+package.definition=sun.,com.sun.xml.internal.ws.,com.sun.xml.internal.bind.,com.sun.imageio.,com.sun.org.apache.xerces.internal.utils.,com.sun.org.apache.xalan.internal.utils. - - # - # Determines whether this properties file can be appended to -diff -r aa04a01605ea -r 549ba5646494 src/share/vm/ci/ciField.cpp ---- hotspot/src/share/vm/ci/ciField.cpp Fri Mar 30 11:34:42 2012 -0700 -+++ hotspot/src/share/vm/ci/ciField.cpp Wed Apr 04 20:44:37 2012 -0700 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -67,7 +67,7 @@ - - // ------------------------------------------------------------------ - // ciField::ciField --ciField::ciField(ciInstanceKlass* klass, int index): _known_to_link_with(NULL) { -+ciField::ciField(ciInstanceKlass* klass, int index): _known_to_link_with_put(NULL), _known_to_link_with_get(NULL) { - ASSERT_IN_VM; - CompilerThread *thread = CompilerThread::current(); - -@@ -143,7 +143,7 @@ - initialize_from(&field_desc); - } - --ciField::ciField(fieldDescriptor *fd): _known_to_link_with(NULL) { -+ciField::ciField(fieldDescriptor *fd): _known_to_link_with_put(NULL), _known_to_link_with_get(NULL) { - ASSERT_IN_VM; - - _cp_index = -1; -@@ -315,6 +315,10 @@ - bool ciField::will_link(ciInstanceKlass* accessing_klass, - Bytecodes::Code bc) { - VM_ENTRY_MARK; -+ assert(bc == Bytecodes::_getstatic || bc == Bytecodes::_putstatic || -+ bc == Bytecodes::_getfield || bc == Bytecodes::_putfield, -+ "unexpected bytecode"); -+ - if (_offset == -1) { - // at creation we couldn't link to our holder so we need to - // maintain that stance, otherwise there's no safe way to use this -@@ -322,8 +326,21 @@ - return false; - } - -- if (_known_to_link_with == accessing_klass) { -- return true; -+ // Check for static/nonstatic mismatch -+ bool is_static = (bc == Bytecodes::_getstatic || bc == Bytecodes::_putstatic); -+ if (is_static != this->is_static()) { -+ return false; -+ } -+ -+ // Get and put can have different accessibility rules -+ bool is_put = (bc == Bytecodes::_putfield || bc == Bytecodes::_putstatic); -+ if (is_put) { -+ if (_known_to_link_with_put == accessing_klass) { -+ return true; -+ } -+ if (_known_to_link_with_get == accessing_klass) { -+ return true; -+ } - } - - FieldAccessInfo result; -@@ -334,8 +351,13 @@ - true, false, KILL_COMPILE_ON_FATAL_(false)); - - // update the hit-cache, unless there is a problem with memory scoping: -- if (accessing_klass->is_shared() || !is_shared()) -- _known_to_link_with = accessing_klass; -+ if (accessing_klass->is_shared() || !is_shared()) { -+ if (is_put) { -+ _known_to_link_with_put = accessing_klass; -+ } else { -+ _known_to_link_with_get = accessing_klass; -+ } -+ } - - return true; - } -diff -r 5b2d6cfb602b -r dcf91dc1f50e src/share/vm/ci/ciField.cpp ---- hotspot/src/share/vm/ci/ciField.cpp Fri Apr 06 14:00:31 2012 -0700 -+++ hotspot/src/share/vm/ci/ciField.cpp Wed Apr 11 17:38:20 2012 -0700 -@@ -338,6 +338,7 @@ - if (_known_to_link_with_put == accessing_klass) { - return true; - } -+ } else { - if (_known_to_link_with_get == accessing_klass) { - return true; - } -diff -r aa04a01605ea -r 549ba5646494 src/share/vm/ci/ciField.hpp ---- hotspot/src/share/vm/ci/ciField.hpp Fri Mar 30 11:34:42 2012 -0700 -+++ hotspot/src/share/vm/ci/ciField.hpp Wed Apr 04 20:44:37 2012 -0700 -@@ -1,5 +1,5 @@ - /* -- * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. -+ * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it -@@ -49,7 +49,8 @@ - ciType* _type; - int _offset; - bool _is_constant; -- ciInstanceKlass* _known_to_link_with; -+ ciInstanceKlass* _known_to_link_with_put; -+ ciInstanceKlass* _known_to_link_with_get; - ciConstant _constant_value; - - // Used for will_link -diff -r 3f8b55667a6f -r abc9f6855a61 src/com/sun/org/apache/xerces/internal/impl/XMLScanner.java ---- jaxp/src/com/sun/org/apache/xerces/internal/impl/XMLScanner.java Fri Mar 30 09:06:09 2012 -0700 -+++ jaxp/src/com/sun/org/apache/xerces/internal/impl/XMLScanner.java Fri Apr 06 09:32:57 2012 -0700 -@@ -402,6 +402,16 @@ - - boolean dataFoundForTarget = false; - boolean sawSpace = fEntityScanner.skipSpaces(); -+ // since pseudoattributes are *not* attributes, -+ // their quotes don't need to be preserved in external parameter entities. -+ // the XMLEntityScanner#scanLiteral method will continue to -+ // emit -1 in such cases when it finds a quote; this is -+ // fine for other methods that parse scanned entities, -+ // but not for the scanning of pseudoattributes. So, -+ // temporarily, we must mark the current entity as not being "literal" -+ Entity.ScannedEntity currEnt = fEntityManager.getCurrentEntity(); -+ boolean currLiteral = currEnt.literal; -+ currEnt.literal = false; - while (fEntityScanner.peekChar() != '?') { - dataFoundForTarget = true; - String name = scanPseudoAttribute(scanningTextDecl, fString); -@@ -499,6 +509,9 @@ - } - sawSpace = fEntityScanner.skipSpaces(); - } -+ // restore original literal value -+ if(currLiteral) -+ currEnt.literal = true; - // REVISIT: should we remove this error reporting? - if (scanningTextDecl && state != STATE_DONE) { - reportFatalError("MorePseudoAttributes", null); -diff -r add74a570ab2 -r bf2255796a93 src/share/vm/classfile/verifier.cpp ---- hotspot/src/share/vm/classfile/verifier.cpp Mon Apr 23 14:26:15 2012 -0700 -+++ hotspot/src/share/vm/classfile/verifier.cpp Thu May 03 15:57:16 2012 -0400 -@@ -1880,10 +1880,10 @@ - VerificationType type = current_frame->pop_stack( - VerificationType::reference_check(), CHECK_VERIFY(this)); - if (type == VerificationType::uninitialized_this_type()) { -- // The method must be an <init> method of either this class, or one of its -- // superclasses -+ // The method must be an <init> method of this class or its superclass -+ klassOop superk = current_class()->super(); - if (ref_class_type.name() != current_class()->name() && -- !name_in_supers(ref_class_type.name(), current_class())) { -+ ref_class_type.name() != superk->klass_part()->name()) { - verify_error(bci, "Bad <init> method call"); - return; - } -diff -r add74a570ab2 -r bf2255796a93 test/runtime/7160757/Test7160757.java ---- hotspot/test/runtime/7160757/Test7160757.java Thu Jan 01 00:00:00 1970 +0000 -+++ hotspot/test/runtime/7160757/Test7160757.java Thu May 03 15:57:16 2012 -0400 -@@ -0,0 +1,82 @@ -+/* -+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. -+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+ * -+ * This code is free software; you can redistribute it and/or modify it -+ * under the terms of the GNU General Public License version 2 only, as -+ * published by the Free Software Foundation. -+ * -+ * This code is distributed in the hope that it will be useful, but WITHOUT -+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -+ * version 2 for more details (a copy is included in the LICENSE file that -+ * accompanied this code). -+ * -+ * You should have received a copy of the GNU General Public License version -+ * 2 along with this work; if not, write to the Free Software Foundation, -+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -+ * -+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -+ * or visit www.oracle.com if you need additional information or have any -+ * questions. -+ */ -+ -+/* -+ * @test Test7160757.java -+ * @bug 7160757 -+ * @summary Tests that superclass initialization is not skipped -+ */ -+ -+public class Test7160757 { -+ -+ public static void main(String args[]) throws Exception { -+ -+ ClassLoader loader = new SLoader(); -+ try { -+ Class.forName("S", true, loader); -+ System.out.println("FAILED"); -+ throw new Exception("Should have thrown a VerifyError."); -+ } catch (VerifyError e) { -+ System.out.println(e); -+ System.out.println("PASSED"); -+ } -+ } -+ -+ static class SLoader extends ClassLoader { -+ -+ /** -+ * public class S extends Throwable { -+ * public S() { -+ * aload_0 -+ * invokespecial Object.<init>() -+ * return -+ * } -+ * } -+ */ -+ static byte b(int i) { return (byte)i; } -+ static byte S_class[] = { -+ b(0xca), b(0xfe), b(0xba), b(0xbe), 0x00, 0x00, 0x00, 0x32, -+ 0x00, 0x0c, 0x0a, 0x00, 0x0b, 0x00, 0x07, 0x07, -+ 0x00, 0x08, 0x07, 0x00, 0x09, 0x01, 0x00, 0x06, -+ 0x3c, 0x69, 0x6e, 0x69, 0x74, 0x3e, 0x01, 0x00, -+ 0x03, 0x28, 0x29, 0x56, 0x01, 0x00, 0x04, 0x43, -+ 0x6f, 0x64, 0x65, 0x0c, 0x00, 0x04, 0x00, 0x05, -+ 0x01, 0x00, 0x01, 0x53, 0x01, 0x00, 0x13, 0x6a, -+ 0x61, 0x76, 0x61, 0x2f, 0x6c, 0x61, 0x6e, 0x67, -+ 0x2f, 0x54, 0x68, 0x72, 0x6f, 0x77, 0x61, 0x62, -+ 0x6c, 0x65, 0x01, 0x00, 0x10, 0x6a, 0x61, 0x76, -+ 0x61, 0x2f, 0x6c, 0x61, 0x6e, 0x67, 0x2f, 0x4f, -+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x07, 0x00, 0x0a, -+ 0x00, 0x21, 0x00, 0x02, 0x00, 0x03, 0x00, 0x00, -+ 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x04, -+ 0x00, 0x05, 0x00, 0x01, 0x00, 0x06, 0x00, 0x00, -+ 0x00, 0x11, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00, -+ 0x00, 0x05, 0x2a, b(0xb7), 0x00, 0x01, b(0xb1), 0x00, -+ 0x00, 0x00, 0x00, 0x00, 0x00 -+ }; -+ -+ public Class findClass(String name) throws ClassNotFoundException { -+ return defineClass(name, S_class, 0, S_class.length); -+ } -+ } -+} -diff -r ba975a730f4b -r c91e36369a9f src/share/classes/java/lang/invoke/MethodHandles.java ---- jdk/src/share/classes/java/lang/invoke/MethodHandles.java Sun May 06 21:25:29 2012 +0100 -+++ jdk/src/share/classes/java/lang/invoke/MethodHandles.java Mon May 07 01:22:07 2012 -0700 -@@ -407,7 +407,7 @@ - * an access$N method. - */ - Lookup() { -- this(getCallerClassAtEntryPoint(), ALL_MODES); -+ this(getCallerClassAtEntryPoint(false), ALL_MODES); - // make sure we haven't accidentally picked up a privileged class: - checkUnprivilegedlookupClass(lookupClass); - } -@@ -461,8 +461,8 @@ - && !VerifyAccess.isSamePackageMember(this.lookupClass, requestedLookupClass)) { - newModes &= ~PRIVATE; - } -- if (newModes == PUBLIC -- && !VerifyAccess.isClassAccessible(requestedLookupClass, this.lookupClass)) { -+ if ((newModes & PUBLIC) != 0 -+ && !VerifyAccess.isClassAccessible(requestedLookupClass, this.lookupClass, allowedModes)) { - // The requested class it not accessible from the lookup class. - // No permissions. - newModes = 0; -@@ -540,13 +540,17 @@ - } - } - -- // call this from an entry point method in Lookup with extraFrames=0. -- private static Class<?> getCallerClassAtEntryPoint() { -+ /* Obtain the external caller class, when called from Lookup.<init> or a first-level subroutine. */ -+ private static Class<?> getCallerClassAtEntryPoint(boolean inSubroutine) { - final int CALLER_DEPTH = 4; -+ // Stack for the constructor entry point (inSubroutine=false): - // 0: Reflection.getCC, 1: getCallerClassAtEntryPoint, - // 2: Lookup.<init>, 3: MethodHandles.*, 4: caller -+ // The stack is slightly different for a subroutine of a Lookup.find* method: -+ // 2: Lookup.*, 3: Lookup.find*.*, 4: caller - // Note: This should be the only use of getCallerClass in this file. -- assert(Reflection.getCallerClass(CALLER_DEPTH-1) == MethodHandles.class); -+ assert(Reflection.getCallerClass(CALLER_DEPTH-2) == Lookup.class); -+ assert(Reflection.getCallerClass(CALLER_DEPTH-1) == (inSubroutine ? Lookup.class : MethodHandles.class)); - return Reflection.getCallerClass(CALLER_DEPTH); - } - -@@ -1086,7 +1090,7 @@ - - void checkSymbolicClass(Class<?> refc) throws IllegalAccessException { - Class<?> caller = lookupClassOrNull(); -- if (caller != null && !VerifyAccess.isClassAccessible(refc, caller)) -+ if (caller != null && !VerifyAccess.isClassAccessible(refc, caller, allowedModes)) - throw new MemberName(refc).makeAccessException("symbolic reference class is not public", this); - } - -@@ -1101,7 +1105,13 @@ - // Step 1: - smgr.checkMemberAccess(refc, Member.PUBLIC); - // Step 2: -- if (!VerifyAccess.classLoaderIsAncestor(lookupClass, refc)) -+ Class<?> callerClass = ((allowedModes & PRIVATE) != 0 -+ ? lookupClass // for strong access modes, no extra check -+ // next line does stack walk magic; do not refactor: -+ : getCallerClassAtEntryPoint(true)); -+ if (!VerifyAccess.classLoaderIsAncestor(lookupClass, refc) || -+ (callerClass != lookupClass && -+ !VerifyAccess.classLoaderIsAncestor(callerClass, refc))) - smgr.checkPackageAccess(VerifyAccess.getPackageName(refc)); - // Step 3: - if (m.isPublic()) return; -@@ -1152,9 +1162,10 @@ - int requestedModes = fixmods(mods); // adjust 0 => PACKAGE - if ((requestedModes & allowedModes) != 0 - && VerifyAccess.isMemberAccessible(refc, m.getDeclaringClass(), -- mods, lookupClass())) -+ mods, lookupClass(), allowedModes)) - return; - if (((requestedModes & ~allowedModes) & PROTECTED) != 0 -+ && (allowedModes & PACKAGE) != 0 - && VerifyAccess.isSamePackage(m.getDeclaringClass(), lookupClass())) - // Protected members can also be checked as if they were package-private. - return; -@@ -1169,9 +1180,9 @@ - (defc == refc || - Modifier.isPublic(refc.getModifiers()))); - if (!classOK && (allowedModes & PACKAGE) != 0) { -- classOK = (VerifyAccess.isClassAccessible(defc, lookupClass()) && -+ classOK = (VerifyAccess.isClassAccessible(defc, lookupClass(), ALL_MODES) && - (defc == refc || -- VerifyAccess.isClassAccessible(refc, lookupClass()))); -+ VerifyAccess.isClassAccessible(refc, lookupClass(), ALL_MODES))); - } - if (!classOK) - return "class is not public"; -diff -r ba975a730f4b -r c91e36369a9f src/share/classes/sun/invoke/util/VerifyAccess.java ---- jdk/src/share/classes/sun/invoke/util/VerifyAccess.java Sun May 06 21:25:29 2012 +0100 -+++ jdk/src/share/classes/sun/invoke/util/VerifyAccess.java Mon May 07 01:22:07 2012 -0700 -@@ -37,6 +37,8 @@ - private VerifyAccess() { } // cannot instantiate - - private static final int PACKAGE_ONLY = 0; -+ private static final int PACKAGE_ALLOWED = java.lang.invoke.MethodHandles.Lookup.PACKAGE; -+ private static final int PROTECTED_OR_PACKAGE_ALLOWED = (PACKAGE_ALLOWED|PROTECTED); - private static final int ALL_ACCESS_MODES = (PUBLIC|PRIVATE|PROTECTED|PACKAGE_ONLY); - private static final boolean ALLOW_NESTMATE_ACCESS = false; - -@@ -82,14 +84,19 @@ - public static boolean isMemberAccessible(Class<?> refc, // symbolic ref class - Class<?> defc, // actual def class - int mods, // actual member mods -- Class<?> lookupClass) { -+ Class<?> lookupClass, -+ int allowedModes) { -+ if (allowedModes == 0) return false; -+ assert((allowedModes & PUBLIC) != 0 && -+ (allowedModes & ~(ALL_ACCESS_MODES|PACKAGE_ALLOWED)) == 0); - // Usually refc and defc are the same, but if they differ, verify them both. - if (refc != defc) { -- if (!isClassAccessible(refc, lookupClass)) { -+ if (!isClassAccessible(refc, lookupClass, allowedModes)) { - // Note that defc is verified in the switch below. - return false; - } -- if ((mods & (ALL_ACCESS_MODES|STATIC)) == (PROTECTED|STATIC)) { -+ if ((mods & (ALL_ACCESS_MODES|STATIC)) == (PROTECTED|STATIC) && -+ (allowedModes & PROTECTED_OR_PACKAGE_ALLOWED) != 0) { - // Apply the special rules for refc here. - if (!isRelatedClass(refc, lookupClass)) - return isSamePackage(defc, lookupClass); -@@ -98,19 +105,28 @@ - // a superclass of the lookup class. - } - } -- if (defc == lookupClass) -+ if (defc == lookupClass && -+ (allowedModes & PRIVATE) != 0) - return true; // easy check; all self-access is OK - switch (mods & ALL_ACCESS_MODES) { - case PUBLIC: - if (refc != defc) return true; // already checked above -- return isClassAccessible(refc, lookupClass); -+ return isClassAccessible(refc, lookupClass, allowedModes); - case PROTECTED: -- return isSamePackage(defc, lookupClass) || isPublicSuperClass(defc, lookupClass); -- case PACKAGE_ONLY: -- return isSamePackage(defc, lookupClass); -+ if ((allowedModes & PROTECTED_OR_PACKAGE_ALLOWED) != 0 && -+ isSamePackage(defc, lookupClass)) -+ return true; -+ if ((allowedModes & PROTECTED) != 0 && -+ isPublicSuperClass(defc, lookupClass)) -+ return true; -+ return false; -+ case PACKAGE_ONLY: // That is, zero. Unmarked member is package-only access. -+ return ((allowedModes & PACKAGE_ALLOWED) != 0 && -+ isSamePackage(defc, lookupClass)); - case PRIVATE: - // Loosened rules for privates follows access rules for inner classes. - return (ALLOW_NESTMATE_ACCESS && -+ (allowedModes & PRIVATE) != 0 && - isSamePackageMember(defc, lookupClass)); - default: - throw new IllegalArgumentException("bad modifiers: "+Modifier.toString(mods)); -@@ -138,11 +154,16 @@ - * @param refc the symbolic reference class to which access is being checked (C) - * @param lookupClass the class performing the lookup (D) - */ -- public static boolean isClassAccessible(Class<?> refc, Class<?> lookupClass) { -+ public static boolean isClassAccessible(Class<?> refc, Class<?> lookupClass, -+ int allowedModes) { -+ if (allowedModes == 0) return false; -+ assert((allowedModes & PUBLIC) != 0 && -+ (allowedModes & ~(ALL_ACCESS_MODES|PACKAGE_ALLOWED)) == 0); - int mods = refc.getModifiers(); - if (isPublic(mods)) - return true; -- if (isSamePackage(lookupClass, refc)) -+ if ((allowedModes & PACKAGE_ALLOWED) != 0 && -+ isSamePackage(lookupClass, refc)) - return true; - return false; - } -@@ -157,7 +178,7 @@ - assert(!class1.isArray() && !class2.isArray()); - if (class1 == class2) - return true; -- if (!loadersAreRelated(class1.getClassLoader(), class2.getClassLoader(), false)) -+ if (class1.getClassLoader() != class2.getClassLoader()) - return false; - String name1 = class1.getName(), name2 = class2.getName(); - int dot = name1.lastIndexOf('.'); -diff -r ba975a730f4b -r c91e36369a9f test/java/lang/invoke/AccessControlTest.java ---- jdk/test/java/lang/invoke/AccessControlTest.java Thu Jan 01 00:00:00 1970 +0000 -+++ jdk/test/java/lang/invoke/AccessControlTest.java Mon May 07 01:22:07 2012 -0700 -@@ -0,0 +1,495 @@ -+/* -+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. -+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+ * -+ * This code is free software; you can redistribute it and/or modify it -+ * under the terms of the GNU General Public License version 2 only, as -+ * published by the Free Software Foundation. Oracle designates this -+ * particular file as subject to the "Classpath" exception as provided -+ * by Oracle in the LICENSE file that accompanied this code. -+ * -+ * This code is distributed in the hope that it will be useful, but WITHOUT -+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -+ * version 2 for more details (a copy is included in the LICENSE file that -+ * accompanied this code). -+ * -+ * You should have received a copy of the GNU General Public License version -+ * 2 along with this work; if not, write to the Free Software Foundation, -+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -+ * -+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -+ * or visit www.oracle.com if you need additional information or have any -+ * questions. -+ */ -+ -+/* @test -+ * @summary test access checking by java.lang.invoke.MethodHandles.Lookup -+ * @library ../../../.. -+ * @build test.java.lang.invoke.AccessControlTest -+ * @build test.java.lang.invoke.AccessControlTest_subpkg.Acquaintance_remote -+ * @run junit/othervm test.java.lang.invoke.AccessControlTest -+ */ -+ -+package test.java.lang.invoke; -+ -+import java.lang.invoke.*; -+import java.lang.reflect.*; -+import java.util.*; -+import org.junit.*; -+ -+import static java.lang.invoke.MethodHandles.*; -+import static java.lang.invoke.MethodHandles.Lookup.*; -+import static java.lang.invoke.MethodType.*; -+import static org.junit.Assert.*; -+import test.java.lang.invoke.AccessControlTest_subpkg.Acquaintance_remote; -+ -+ -+/** -+ * Test many combinations of Lookup access and cross-class lookupStatic. -+ * @author jrose -+ */ -+public class AccessControlTest { -+ static final Class<?> THIS_CLASS = AccessControlTest.class; -+ // How much output? -+ static int verbosity = 0; -+ static { -+ String vstr = System.getProperty(THIS_CLASS.getSimpleName()+".verbosity"); -+ if (vstr == null) -+ vstr = System.getProperty(THIS_CLASS.getName()+".verbosity"); -+ if (vstr != null) verbosity = Integer.parseInt(vstr); -+ } -+ -+ private class LookupCase implements Comparable<LookupCase> { -+ final Lookup lookup; -+ final Class<?> lookupClass; -+ final int lookupModes; -+ public LookupCase(Lookup lookup) { -+ this.lookup = lookup; -+ this.lookupClass = lookup.lookupClass(); -+ this.lookupModes = lookup.lookupModes(); -+ assert(lookupString().equals(lookup.toString())); -+ numberOf(lookupClass().getClassLoader()); // assign CL# -+ } -+ public LookupCase(Class<?> lookupClass, int lookupModes) { -+ this.lookup = null; -+ this.lookupClass = lookupClass; -+ this.lookupModes = lookupModes; -+ numberOf(lookupClass().getClassLoader()); // assign CL# -+ } -+ -+ public final Class<?> lookupClass() { return lookupClass; } -+ public final int lookupModes() { return lookupModes; } -+ -+ public Lookup lookup() { lookup.getClass(); return lookup; } -+ -+ @Override -+ public int compareTo(LookupCase that) { -+ Class<?> c1 = this.lookupClass(); -+ Class<?> c2 = that.lookupClass(); -+ if (c1 != c2) { -+ int cmp = c1.getName().compareTo(c2.getName()); -+ if (cmp != 0) return cmp; -+ cmp = numberOf(c1.getClassLoader()) - numberOf(c2.getClassLoader()); -+ assert(cmp != 0); -+ return cmp; -+ } -+ return -(this.lookupModes() - that.lookupModes()); -+ } -+ -+ @Override -+ public boolean equals(Object that) { -+ return (that instanceof LookupCase && equals((LookupCase)that)); -+ } -+ public boolean equals(LookupCase that) { -+ return (this.lookupClass() == that.lookupClass() && -+ this.lookupModes() == that.lookupModes()); -+ } -+ -+ @Override -+ public int hashCode() { -+ return lookupClass().hashCode() + (lookupModes() * 31); -+ } -+ -+ /** Simulate all assertions in the spec. for Lookup.toString. */ -+ private String lookupString() { -+ String name = lookupClass.getName(); -+ String suffix = ""; -+ if (lookupModes == 0) -+ suffix = "/noaccess"; -+ else if (lookupModes == PUBLIC) -+ suffix = "/public"; -+ else if (lookupModes == (PUBLIC|PACKAGE)) -+ suffix = "/package"; -+ else if (lookupModes == (PUBLIC|PACKAGE|PRIVATE)) -+ suffix = "/private"; -+ else if (lookupModes == (PUBLIC|PACKAGE|PRIVATE|PROTECTED)) -+ suffix = ""; -+ else -+ suffix = "/#"+Integer.toHexString(lookupModes); -+ return name+suffix; -+ } -+ -+ /** Simulate all assertions from the spec. for Lookup.in: -+ * <hr/> -+ * Creates a lookup on the specified new lookup class. -+ * [A1] The resulting object will report the specified -+ * class as its own {@link #lookupClass lookupClass}. -+ * <p> -+ * [A2] However, the resulting {@code Lookup} object is guaranteed -+ * to have no more access capabilities than the original. -+ * In particular, access capabilities can be lost as follows:<ul> -+ * <li>[A3] If the new lookup class differs from the old one, -+ * protected members will not be accessible by virtue of inheritance. -+ * (Protected members may continue to be accessible because of package sharing.) -+ * <li>[A4] If the new lookup class is in a different package -+ * than the old one, protected and default (package) members will not be accessible. -+ * <li>[A5] If the new lookup class is not within the same package member -+ * as the old one, private members will not be accessible. -+ * <li>[A6] If the new lookup class is not accessible to the old lookup class, -+ * using the original access modes, -+ * then no members, not even public members, will be accessible. -+ * [A7] (In all other cases, public members will continue to be accessible.) -+ * </ul> -+ * Other than the above cases, the new lookup will have the same -+ * access capabilities as the original. [A8] -+ * <hr/> -+ */ -+ public LookupCase in(Class<?> c2) { -+ Class<?> c1 = lookupClass(); -+ int m1 = lookupModes(); -+ int changed = 0; -+ boolean samePackage = (c1.getClassLoader() == c2.getClassLoader() && -+ packagePrefix(c1).equals(packagePrefix(c2))); -+ boolean sameTopLevel = (topLevelClass(c1) == topLevelClass(c2)); -+ boolean sameClass = (c1 == c2); -+ assert(samePackage || !sameTopLevel); -+ assert(sameTopLevel || !sameClass); -+ boolean accessible = sameClass; // [A6] -+ if ((m1 & PACKAGE) != 0) accessible |= samePackage; -+ if ((m1 & PUBLIC ) != 0) accessible |= (c2.getModifiers() & PUBLIC) != 0; -+ if (!accessible) { -+ // Different package and no access to c2; lose all access. -+ changed |= (PUBLIC|PACKAGE|PRIVATE|PROTECTED); // [A6] -+ } -+ if (!samePackage) { -+ // Different package; lose PACKAGE and lower access. -+ changed |= (PACKAGE|PRIVATE|PROTECTED); // [A4] -+ } -+ if (!sameTopLevel) { -+ // Different top-level class. Lose PRIVATE and lower access. -+ changed |= (PRIVATE|PROTECTED); // [A5] -+ } -+ if (!sameClass) { -+ changed |= (PROTECTED); // [A3] -+ } else { -+ assert(changed == 0); // [A8] (no deprivation if same class) -+ } -+ if (accessible) assert((changed & PUBLIC) == 0); // [A7] -+ int m2 = m1 & ~changed; -+ LookupCase l2 = new LookupCase(c2, m2); -+ assert(l2.lookupClass() == c2); // [A1] -+ assert((m1 | m2) == m1); // [A2] (no elevation of access) -+ return l2; -+ } -+ -+ @Override -+ public String toString() { -+ String s = lookupClass().getSimpleName(); -+ String lstr = lookupString(); -+ int sl = lstr.indexOf('/'); -+ if (sl >= 0) s += lstr.substring(sl); -+ ClassLoader cld = lookupClass().getClassLoader(); -+ if (cld != THIS_LOADER) s += "/loader#"+numberOf(cld); -+ return s; -+ } -+ -+ /** Predict the success or failure of accessing this method. */ -+ public boolean willAccess(Method m) { -+ Class<?> c1 = lookupClass(); -+ Class<?> c2 = m.getDeclaringClass(); -+ LookupCase lc = this.in(c2); -+ int m1 = lc.lookupModes(); -+ int m2 = fixMods(m.getModifiers()); -+ // privacy is strictly enforced on lookups -+ if (c1 != c2) m1 &= ~PRIVATE; -+ // protected access is sometimes allowed -+ if ((m2 & PROTECTED) != 0) { -+ int prev = m2; -+ m2 |= PACKAGE; // it acts like a package method also -+ if ((lookupModes() & PROTECTED) != 0 && -+ c2.isAssignableFrom(c1)) -+ m2 |= PUBLIC; // from a subclass, it acts like a public method also -+ } -+ if (verbosity >= 2) -+ System.out.println(this+" willAccess "+lc+" m1="+m1+" m2="+m2+" => "+((m2 & m1) != 0)); -+ return (m2 & m1) != 0; -+ } -+ } -+ -+ private static Class<?> topLevelClass(Class<?> cls) { -+ Class<?> c = cls; -+ for (Class<?> ec; (ec = c.getEnclosingClass()) != null; ) -+ c = ec; -+ assert(c.getEnclosingClass() == null); -+ assert(c == cls || cls.getEnclosingClass() != null); -+ return c; -+ } -+ -+ private static String packagePrefix(Class<?> c) { -+ while (c.isArray()) c = c.getComponentType(); -+ String s = c.getName(); -+ assert(s.indexOf('/') < 0); -+ return s.substring(0, s.lastIndexOf('.')+1); -+ } -+ -+ -+ private final TreeSet<LookupCase> CASES = new TreeSet<>(); -+ private final TreeMap<LookupCase,TreeSet<LookupCase>> CASE_EDGES = new TreeMap<>(); -+ private final ArrayList<ClassLoader> LOADERS = new ArrayList<>(); -+ private final ClassLoader THIS_LOADER = this.getClass().getClassLoader(); -+ { if (THIS_LOADER != null) LOADERS.add(THIS_LOADER); } // #1 -+ -+ private LookupCase lookupCase(String name) { -+ for (LookupCase lc : CASES) { -+ if (lc.toString().equals(name)) -+ return lc; -+ } -+ throw new AssertionError(name); -+ } -+ -+ private int numberOf(ClassLoader cl) { -+ if (cl == null) return 0; -+ int i = LOADERS.indexOf(cl); -+ if (i < 0) { -+ i = LOADERS.size(); -+ LOADERS.add(cl); -+ } -+ return i+1; -+ } -+ -+ private void addLookupEdge(LookupCase l1, Class<?> c2, LookupCase l2) { -+ TreeSet<LookupCase> edges = CASE_EDGES.get(l2); -+ if (edges == null) CASE_EDGES.put(l2, edges = new TreeSet<>()); -+ if (edges.add(l1)) { -+ Class<?> c1 = l1.lookupClass(); -+ assert(l2.lookupClass() == c2); // [A1] -+ int m1 = l1.lookupModes(); -+ int m2 = l2.lookupModes(); -+ assert((m1 | m2) == m1); // [A2] (no elevation of access) -+ LookupCase expect = l1.in(c2); -+ if (!expect.equals(l2)) -+ System.out.println("*** expect "+l1+" => "+expect+" but got "+l2); -+ assertEquals(expect, l2); -+ } -+ } -+ -+ private void makeCases(Lookup[] originalLookups) { -+ // make initial set of lookup test cases -+ CASES.clear(); LOADERS.clear(); CASE_EDGES.clear(); -+ ArrayList<Class<?>> classes = new ArrayList<>(); -+ for (Lookup l : originalLookups) { -+ CASES.add(new LookupCase(l)); -+ classes.remove(l.lookupClass()); // no dups please -+ classes.add(l.lookupClass()); -+ } -+ System.out.println("loaders = "+LOADERS); -+ int rounds = 0; -+ for (int lastCount = -1; lastCount != CASES.size(); ) { -+ lastCount = CASES.size(); // if CASES grow in the loop we go round again -+ for (LookupCase lc1 : CASES.toArray(new LookupCase[0])) { -+ for (Class<?> c2 : classes) { -+ LookupCase lc2 = new LookupCase(lc1.lookup().in(c2)); -+ addLookupEdge(lc1, c2, lc2); -+ CASES.add(lc2); -+ } -+ } -+ rounds++; -+ } -+ System.out.println("filled in "+CASES.size()+" cases from "+originalLookups.length+" original cases in "+rounds+" rounds"); -+ if (false) { -+ System.out.println("CASES: {"); -+ for (LookupCase lc : CASES) { -+ System.out.println(lc); -+ Set<LookupCase> edges = CASE_EDGES.get(lc); -+ if (edges != null) -+ for (LookupCase prev : edges) { -+ System.out.println("\t"+prev); -+ } -+ } -+ System.out.println("}"); -+ } -+ } -+ -+ @Test public void test() { -+ makeCases(lookups()); -+ if (verbosity > 0) { -+ verbosity += 9; -+ Method pro_in_self = targetMethod(THIS_CLASS, PROTECTED, methodType(void.class)); -+ testOneAccess(lookupCase("AccessControlTest/public"), pro_in_self, "find"); -+ testOneAccess(lookupCase("Remote_subclass/public"), pro_in_self, "find"); -+ testOneAccess(lookupCase("Remote_subclass"), pro_in_self, "find"); -+ verbosity -= 9; -+ } -+ Set<Class<?>> targetClassesDone = new HashSet<>(); -+ for (LookupCase targetCase : CASES) { -+ Class<?> targetClass = targetCase.lookupClass(); -+ if (!targetClassesDone.add(targetClass)) continue; // already saw this one -+ String targetPlace = placeName(targetClass); -+ if (targetPlace == null) continue; // Object, String, not a target -+ for (int targetAccess : ACCESS_CASES) { -+ MethodType methodType = methodType(void.class); -+ Method method = targetMethod(targetClass, targetAccess, methodType); -+ // Try to access target method from various contexts. -+ for (LookupCase sourceCase : CASES) { -+ testOneAccess(sourceCase, method, "find"); -+ testOneAccess(sourceCase, method, "unreflect"); -+ } -+ } -+ } -+ System.out.println("tested "+testCount+" access scenarios; "+testCountFails+" accesses were denied"); -+ } -+ -+ private int testCount, testCountFails; -+ -+ private void testOneAccess(LookupCase sourceCase, Method method, String kind) { -+ Class<?> targetClass = method.getDeclaringClass(); -+ String methodName = method.getName(); -+ MethodType methodType = methodType(method.getReturnType(), method.getParameterTypes()); -+ boolean willAccess = sourceCase.willAccess(method); -+ boolean didAccess = false; -+ ReflectiveOperationException accessError = null; -+ try { -+ switch (kind) { -+ case "find": -+ if ((method.getModifiers() & Modifier.STATIC) != 0) -+ sourceCase.lookup().findStatic(targetClass, methodName, methodType); -+ else -+ sourceCase.lookup().findVirtual(targetClass, methodName, methodType); -+ break; -+ case "unreflect": -+ sourceCase.lookup().unreflect(method); -+ break; -+ default: -+ throw new AssertionError(kind); -+ } -+ didAccess = true; -+ } catch (ReflectiveOperationException ex) { -+ accessError = ex; -+ } -+ if (willAccess != didAccess) { -+ System.out.println(sourceCase+" => "+targetClass.getSimpleName()+"."+methodName+methodType); -+ System.out.println("fail on "+method+" ex="+accessError); -+ assertEquals(willAccess, didAccess); -+ } -+ testCount++; -+ if (!didAccess) testCountFails++; -+ } -+ -+ static Method targetMethod(Class<?> targetClass, int targetAccess, MethodType methodType) { -+ String methodName = accessName(targetAccess)+placeName(targetClass); -+ if (verbosity >= 2) -+ System.out.println(targetClass.getSimpleName()+"."+methodName+methodType); -+ try { -+ Method method = targetClass.getDeclaredMethod(methodName, methodType.parameterArray()); -+ assertEquals(method.getReturnType(), methodType.returnType()); -+ int haveMods = method.getModifiers(); -+ assert(Modifier.isStatic(haveMods)); -+ assert(targetAccess == fixMods(haveMods)); -+ return method; -+ } catch (NoSuchMethodException ex) { -+ throw new AssertionError(methodName, ex); -+ } -+ } -+ -+ static String placeName(Class<?> cls) { -+ // return "self", "sibling", "nestmate", etc. -+ if (cls == AccessControlTest.class) return "self"; -+ String cln = cls.getSimpleName(); -+ int under = cln.lastIndexOf('_'); -+ if (under < 0) return null; -+ return cln.substring(under+1); -+ } -+ static String accessName(int acc) { -+ switch (acc) { -+ case PUBLIC: return "pub_in_"; -+ case PROTECTED: return "pro_in_"; -+ case PACKAGE: return "pkg_in_"; -+ case PRIVATE: return "pri_in_"; -+ } -+ assert(false); -+ return "?"; -+ } -+ private static final int[] ACCESS_CASES = { -+ PUBLIC, PACKAGE, PRIVATE, PROTECTED -+ }; -+ /** Return one of the ACCESS_CASES. */ -+ static int fixMods(int mods) { -+ mods &= (PUBLIC|PRIVATE|PROTECTED); -+ switch (mods) { -+ case PUBLIC: case PRIVATE: case PROTECTED: return mods; -+ case 0: return PACKAGE; -+ } -+ throw new AssertionError(mods); -+ } -+ -+ static Lookup[] lookups() { -+ ArrayList<Lookup> tem = new ArrayList<>(); -+ Collections.addAll(tem, -+ AccessControlTest.lookup_in_self(), -+ Inner_nestmate.lookup_in_nestmate(), -+ AccessControlTest_sibling.lookup_in_sibling()); -+ if (true) { -+ Collections.addAll(tem,Acquaintance_remote.lookups()); -+ } else { -+ try { -+ Class<?> remc = Class.forName("test.java.lang.invoke.AccessControlTest_subpkg.Acquaintance_remote"); -+ Lookup[] remls = (Lookup[]) remc.getMethod("lookups").invoke(null); -+ Collections.addAll(tem, remls); -+ } catch (ReflectiveOperationException ex) { -+ throw new LinkageError("reflection failed", ex); -+ } -+ } -+ tem.add(publicLookup()); -+ tem.add(publicLookup().in(String.class)); -+ tem.add(publicLookup().in(List.class)); -+ return tem.toArray(new Lookup[0]); -+ } -+ -+ static Lookup lookup_in_self() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_self() { } -+ static protected void pro_in_self() { } -+ static /*package*/ void pkg_in_self() { } -+ static private void pri_in_self() { } -+ -+ static class Inner_nestmate { -+ static Lookup lookup_in_nestmate() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_nestmate() { } -+ static protected void pro_in_nestmate() { } -+ static /*package*/ void pkg_in_nestmate() { } -+ static private void pri_in_nestmate() { } -+ } -+} -+class AccessControlTest_sibling { -+ static Lookup lookup_in_sibling() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_sibling() { } -+ static protected void pro_in_sibling() { } -+ static /*package*/ void pkg_in_sibling() { } -+ static private void pri_in_sibling() { } -+} -+ -+// This guy tests access from outside the package: -+/* -+package test.java.lang.invoke.AccessControlTest_subpkg; -+public class Acquaintance_remote { -+ public static Lookup[] lookups() { ... -+ } -+ ... -+} -+*/ -diff -r ba975a730f4b -r c91e36369a9f test/java/lang/invoke/AccessControlTest_subpkg/Acquaintance_remote.java ---- jdk/test/java/lang/invoke/AccessControlTest_subpkg/Acquaintance_remote.java Thu Jan 01 00:00:00 1970 +0000 -+++ jdk/test/java/lang/invoke/AccessControlTest_subpkg/Acquaintance_remote.java Mon May 07 01:22:07 2012 -0700 -@@ -0,0 +1,42 @@ -+package test.java.lang.invoke.AccessControlTest_subpkg; -+import test.java.lang.invoke.AccessControlTest; -+import java.lang.invoke.*; -+import static java.lang.invoke.MethodHandles.*; -+ -+// This guy tests access from outside the package test.java.lang.invoke: -+public class Acquaintance_remote { -+ public static Lookup[] lookups() { -+ return new Lookup[] { -+ Acquaintance_remote.lookup_in_remote(), -+ Remote_subclass.lookup_in_subclass(), -+ Remote_hidden.lookup_in_hidden() -+ }; -+ } -+ -+ public static Lookup lookup_in_remote() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_remote() { } -+ static protected void pro_in_remote() { } -+ static /*package*/ void pkg_in_remote() { } -+ static private void pri_in_remote() { } -+ -+ static public class Remote_subclass extends AccessControlTest { -+ static Lookup lookup_in_subclass() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_subclass() { } -+ static protected void pro_in_subclass() { } -+ static /*package*/ void pkg_in_subclass() { } -+ static private void pri_in_subclass() { } -+ } -+ static /*package*/ class Remote_hidden { -+ static Lookup lookup_in_hidden() { -+ return MethodHandles.lookup(); -+ } -+ static public void pub_in_hidden() { } -+ static protected void pro_in_hidden() { } -+ static /*package*/ void pkg_in_hidden() { } -+ static private void pri_in_hidden() { } -+ } -+} |