--- a/jdk/make/Makefile Tue Mar 31 08:48:53 2015 -0700
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-#
-# Copyright (c) 2012, 2013, 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.
-#
-
-# Locate this Makefile
-ifeq ($(filter /%, $(lastword $(MAKEFILE_LIST))), )
- makefile_path := $(CURDIR)/$(lastword $(MAKEFILE_LIST))
-else
- makefile_path := $(lastword $(MAKEFILE_LIST))
-endif
-repo_dir := $(patsubst %/make/Makefile, %, $(makefile_path))
-
-# What is the name of this subsystem (langtools, corba, etc)?
-subsystem_name := $(notdir $(repo_dir))
-
-# Try to locate top-level makefile
-top_level_makefile := $(repo_dir)/../Makefile
-ifneq ($(wildcard $(top_level_makefile)), )
- $(info Will run $(subsystem_name) target on top-level Makefile)
- $(info WARNING: This is a non-recommended way of building!)
- $(info ===================================================)
-else
- $(info Cannot locate top-level Makefile. Is this repo not checked out as part of a complete forest?)
- $(error Build from top-level Makefile instead)
-endif
-
-all:
- @$(MAKE) -f $(top_level_makefile) $(subsystem_name)
--- a/jdk/make/copy/Copy-java.base.gmk Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/copy/Copy-java.base.gmk Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2014, 2015 Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2014, 2015, 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
@@ -98,6 +98,8 @@
JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/macosx/conf/$(JVMCFG_ARCH)/jvm.cfg
else
JVMCFG_SRC := $(JDK_TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_TYPE)/conf/$(JVMCFG_ARCH)/jvm.cfg
+ # Allow override by ALT_JVMCFG_SRC if it exists
+ JVMCFG_SRC := $(if $(wildcard $(ALT_JVMCFG_SRC)),$(ALT_JVMCFG_SRC),$(JVMCFG_SRC))
endif
JVMCFG_DIR := $(LIB_DST_DIR)$(OPENJDK_TARGET_CPU_LIBDIR)
JVMCFG := $(JVMCFG_DIR)/jvm.cfg
--- a/jdk/make/data/tzdata/VERSION Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/VERSION Tue Mar 31 16:23:01 2015 -0700
@@ -21,4 +21,4 @@
# or visit www.oracle.com if you need additional information or have any
# questions.
#
-tzdata2015a
+tzdata2015b
--- a/jdk/make/data/tzdata/asia Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/asia Tue Mar 31 16:23:01 2015 -0700
@@ -1927,6 +1927,13 @@
# was at the start of 2008-03-31 (the day of Steffen Thorsen's report);
# this is almost surely wrong.
+# From Ganbold Tsagaankhuu (2015-03-10):
+# It seems like yesterday Mongolian Government meeting has concluded to use
+# daylight saving time in Mongolia.... Starting at 2:00AM of last Saturday of
+# March 2015, daylight saving time starts. And 00:00AM of last Saturday of
+# September daylight saving time ends. Source:
+# http://zasag.mn/news/view/8969
+
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Mongol 1983 1984 - Apr 1 0:00 1:00 S
Rule Mongol 1983 only - Oct 1 0:00 0 -
@@ -1947,6 +1954,8 @@
Rule Mongol 2001 only - Apr lastSat 2:00 1:00 S
Rule Mongol 2001 2006 - Sep lastSat 2:00 0 -
Rule Mongol 2002 2006 - Mar lastSat 2:00 1:00 S
+Rule Mongol 2015 max - Mar lastSat 2:00 1:00 S
+Rule Mongol 2015 max - Sep lastSat 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
# Hovd, a.k.a. Chovd, Dund-Us, Dzhargalant, Khovd, Jirgalanta
@@ -2365,13 +2374,19 @@
# official source...:
# http://www.palestinecabinet.gov.ps/ar/Views/ViewDetails.aspx?pid=1252
-# From Paul Eggert (2013-09-24):
-# For future dates, guess the last Thursday in March at 24:00 through
-# the first Friday on or after September 21 at 00:00. This is consistent with
-# the predictions in today's editions of the following URLs,
-# which are for Gaza and Hebron respectively:
-# http://www.timeanddate.com/worldclock/timezone.html?n=702
-# http://www.timeanddate.com/worldclock/timezone.html?n=2364
+# From Steffen Thorsen (2015-03-03):
+# Sources such as http://www.alquds.com/news/article/view/id/548257
+# and http://www.raya.ps/ar/news/890705.html say Palestine areas will
+# start DST on 2015-03-28 00:00 which is one day later than expected.
+#
+# From Paul Eggert (2015-03-03):
+# http://www.timeanddate.com/time/change/west-bank/ramallah?year=2014
+# says that the fall 2014 transition was Oct 23 at 24:00.
+# For future dates, guess the last Friday in March at 24:00 through
+# the first Friday on or after October 21 at 00:00. This is consistent with
+# the predictions in today's editions of the following URLs:
+# http://www.timeanddate.com/time/change/gaza-strip/gaza
+# http://www.timeanddate.com/time/change/west-bank/hebron
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule EgyptAsia 1957 only - May 10 0:00 1:00 S
@@ -2397,9 +2412,11 @@
Rule Palestine 2011 only - Aug 1 0:00 0 -
Rule Palestine 2011 only - Aug 30 0:00 1:00 S
Rule Palestine 2011 only - Sep 30 0:00 0 -
-Rule Palestine 2012 max - Mar lastThu 24:00 1:00 S
+Rule Palestine 2012 2014 - Mar lastThu 24:00 1:00 S
Rule Palestine 2012 only - Sep 21 1:00 0 -
-Rule Palestine 2013 max - Sep Fri>=21 0:00 0 -
+Rule Palestine 2013 only - Sep Fri>=21 0:00 0 -
+Rule Palestine 2014 max - Oct Fri>=21 0:00 0 -
+Rule Palestine 2015 max - Mar lastFri 24:00 1:00 S
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Gaza 2:17:52 - LMT 1900 Oct
--- a/jdk/make/data/tzdata/australasia Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/australasia Tue Mar 31 16:23:01 2015 -0700
@@ -396,6 +396,7 @@
9:39:00 - LMT 1901 # Agana
10:00 - GST 2000 Dec 23 # Guam
10:00 - ChST # Chamorro Standard Time
+Link Pacific/Guam Pacific/Saipan # N Mariana Is
# Kiribati
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -411,12 +412,7 @@
14:00 - LINT
# N Mariana Is
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone Pacific/Saipan -14:17:00 - LMT 1844 Dec 31
- 9:43:00 - LMT 1901
- 9:00 - MPT 1969 Oct # N Mariana Is Time
- 10:00 - MPT 2000 Dec 23
- 10:00 - ChST # Chamorro Standard Time
+# See Pacific/Guam.
# Marshall Is
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -586,6 +582,7 @@
-11:00 - NST 1967 Apr # N=Nome
-11:00 - BST 1983 Nov 30 # B=Bering
-11:00 - SST # S=Samoa
+Link Pacific/Pago_Pago Pacific/Midway # in US minor outlying islands
# Samoa (formerly and also known as Western Samoa)
@@ -767,23 +764,7 @@
# uninhabited
# Midway
-#
-# From Mark Brader (2005-01-23):
-# [Fallacies and Fantasies of Air Transport History, by R.E.G. Davies,
-# published 1994 by Paladwr Press, McLean, VA, USA; ISBN 0-9626483-5-3]
-# reproduced a Pan American Airways timetable from 1936, for their weekly
-# "Orient Express" flights between San Francisco and Manila, and connecting
-# flights to Chicago and the US East Coast. As it uses some time zone
-# designations that I've never seen before:....
-# Fri. 6:30A Lv. HONOLOLU (Pearl Harbor), H.I. H.L.T. Ar. 5:30P Sun.
-# " 3:00P Ar. MIDWAY ISLAND . . . . . . . . . M.L.T. Lv. 6:00A "
-#
-Zone Pacific/Midway -11:49:28 - LMT 1901
- -11:00 - NST 1956 Jun 3
- -11:00 1:00 NDT 1956 Sep 2
- -11:00 - NST 1967 Apr # N=Nome
- -11:00 - BST 1983 Nov 30 # B=Bering
- -11:00 - SST # S=Samoa
+# See Pacific/Pago_Pago.
# Palmyra
# uninhabited since World War II; was probably like Pacific/Kiritimati
--- a/jdk/make/data/tzdata/europe Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/europe Tue Mar 31 16:23:01 2015 -0700
@@ -2423,7 +2423,7 @@
4:00 Russia VOL%sT 1989 Mar 26 2:00s # Volgograd T
3:00 Russia VOL%sT 1991 Mar 31 2:00s
4:00 - VOLT 1992 Mar 29 2:00s
- 3:00 Russia MSK 2011 Mar 27 2:00s
+ 3:00 Russia MSK/MSD 2011 Mar 27 2:00s
4:00 - MSK 2014 Oct 26 2:00s
3:00 - MSK
--- a/jdk/make/data/tzdata/northamerica Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/northamerica Tue Mar 31 16:23:01 2015 -0700
@@ -2335,8 +2335,24 @@
# "...the new time zone will come into effect at two o'clock on the first Sunday
# of February, when we will have to advance the clock one hour from its current
# time..."
+# Also, the new zone will not use DST.
#
-# Also, the new zone will not use DST.
+# From Carlos Raúl Perasso (2015-02-02):
+# The decree that modifies the Mexican Hour System Law has finally
+# been published at the Diario Oficial de la Federación
+# http://www.dof.gob.mx/nota_detalle.php?codigo=5380123&fecha=31/01/2015
+# It establishes 5 zones for Mexico:
+# 1- Zona Centro (Central Zone): Corresponds to longitude 90 W,
+# includes most of Mexico, excluding what's mentioned below.
+# 2- Zona Pacífico (Pacific Zone): Longitude 105 W, includes the
+# states of Baja California Sur; Chihuahua; Nayarit (excluding Bahía
+# de Banderas which lies in Central Zone); Sinaloa and Sonora.
+# 3- Zona Noroeste (Northwest Zone): Longitude 120 W, includes the
+# state of Baja California.
+# 4- Zona Sureste (Southeast Zone): Longitude 75 W, includes the state
+# of Quintana Roo.
+# 5- The islands, reefs and keys shall take their timezone from the
+# longitude they are located at.
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Mexico 1939 only - Feb 5 0:00 1:00 D
@@ -2531,14 +2547,9 @@
###############################################################################
# Anguilla
+# Antigua and Barbuda
# See America/Port_of_Spain.
-# Antigua and Barbuda
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone America/Antigua -4:07:12 - LMT 1912 Mar 2
- -5:00 - EST 1951
- -4:00 - AST
-
# Bahamas
#
# For 1899 Milne gives -5:09:29.5; round that.
@@ -2604,10 +2615,7 @@
-4:00 US A%sT
# Cayman Is
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone America/Cayman -5:25:32 - LMT 1890 # Georgetown
- -5:07:11 - KMT 1912 Feb # Kingston Mean Time
- -5:00 - EST
+# See America/Panama.
# Costa Rica
@@ -3130,6 +3138,7 @@
Zone America/Panama -5:18:08 - LMT 1890
-5:19:36 - CMT 1908 Apr 22 # Colón Mean Time
-5:00 - EST
+Link America/Panama America/Cayman
# Puerto Rico
# There are too many San Juans elsewhere, so we'll use 'Puerto_Rico'.
--- a/jdk/make/data/tzdata/southamerica Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/data/tzdata/southamerica Tue Mar 31 16:23:01 2015 -0700
@@ -1229,10 +1229,13 @@
# DST Start: first Saturday of September 2014 (Sun 07 Sep 2014 04:00 UTC)
# http://www.diariooficial.interior.gob.cl//media/2014/02/19/do-20140219.pdf
-# From Juan Correa (2015-01-28):
-# ... today the Ministry of Energy announced that Chile will drop DST, will keep
-# "summer time" (UTC -3 / UTC -5) all year round....
-# http://www.minenergia.cl/ministerio/noticias/generales/ministerio-de-energia-anuncia.html
+# From Eduardo Romero Urra (2015-03-03):
+# Today has been published officially that Chile will use the DST time
+# permanently until March 25 of 2017
+# http://www.diariooficial.interior.gob.cl/media/2015/03/03/1-large.jpg
+#
+# From Paul Eggert (2015-03-03):
+# For now, assume that the extension will persist indefinitely.
# NOTE: ChileAQ rules for Antarctic bases are stored separately in the
# 'antarctica' file.
@@ -1291,7 +1294,7 @@
-3:00 - CLT
Zone Pacific/Easter -7:17:44 - LMT 1890
-7:17:28 - EMT 1932 Sep # Easter Mean Time
- -7:00 Chile EAS%sT 1982 Mar 13 3:00u # Easter Time
+ -7:00 Chile EAS%sT 1982 Mar 14 3:00u # Easter Time
-6:00 Chile EAS%sT 2015 Apr 26 3:00u
-5:00 - EAST
#
@@ -1626,6 +1629,7 @@
# These all agree with Trinidad and Tobago since 1970.
Link America/Port_of_Spain America/Anguilla
+Link America/Port_of_Spain America/Antigua
Link America/Port_of_Spain America/Dominica
Link America/Port_of_Spain America/Grenada
Link America/Port_of_Spain America/Guadeloupe
--- a/jdk/make/mapfiles/libjava/reorder-sparc Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/mapfiles/libjava/reorder-sparc Tue Mar 31 16:23:01 2015 -0700
@@ -1,7 +1,6 @@
data = R0x2000;
text = LOAD ?RXO;
# Test Null
-text: .text%init64IO: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%JNI_OnLoad;
text: .text%Canonicalize;
text: .text%canonicalize;
@@ -38,10 +37,9 @@
text: .text%Java_java_lang_System_identityHashCode;
text: .text%Java_sun_misc_Signal_findSignal;
text: .text%Java_sun_misc_Signal_handle0;
-text: .text%Java_java_io_FileSystem_getFileSystem;
text: .text%JNU_NewObjectByName;
text: .text%Java_java_io_UnixFileSystem_initIDs;
-text: .text%Java_java_io_UnixFileSystem_canonicalize;
+text: .text%Java_java_io_UnixFileSystem_canonicalize0;
text: .text%JNU_GetStringPlatformChars;
text: .text%JNU_ReleaseStringPlatformChars;
text: .text%Java_java_io_FileInputStream_open0;
@@ -52,27 +50,25 @@
text: .text%Java_java_io_FileInputStream_close0;
text: .text%Java_java_lang_System_mapLibraryName;
text: .text%Java_java_io_UnixFileSystem_getBooleanAttributes0;
-text: .text%statMode: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_load;
-text: .text%Java_java_lang_Compiler_registerNatives;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_find;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2;
text: .text%Java_java_io_UnixFileSystem_list;
text: .text%JNU_ClassString;
text: .text%JNU_CopyObjectArray;
text: .text%Java_java_lang_String_intern;
-text: .text%Java_java_lang_ClassLoader_findLoadedClass;
+text: .text%Java_java_lang_ClassLoader_findLoadedClass0;
text: .text%Java_java_lang_ClassLoader_findBootstrapClass;
text: .text%Java_java_lang_Throwable_fillInStackTrace;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2Ljava_security_AccessControlContext_2;
text: .text%Java_java_io_UnixFileSystem_getLastModifiedTime;
-text: .text%Java_java_lang_Float_floatToIntBits;
-text: .text%Java_java_lang_Double_doubleToLongBits;
+text: .text%Java_java_lang_Float_floatToRawIntBits;
+text: .text%Java_java_lang_Double_doubleToRawLongBits;
text: .text%Java_java_io_UnixFileSystem_getLength;
text: .text%Java_java_lang_ClassLoader_defineClass0;
text: .text%VerifyClassCodes;
# Test Exit
-text: .text%Java_java_lang_Shutdown_halt;
+text: .text%Java_java_lang_Shutdown_halt0;
# Test Hello
text: .text%Java_java_io_FileOutputStream_writeBytes;
text: .text%writeBytes;
@@ -91,9 +87,7 @@
text: .text%JNU_CallMethodByName;
text: .text%JNU_CallMethodByNameV;
text: .text%Java_java_io_UnixFileSystem_createDirectory;
-text: .text%Java_java_util_prefs_FileSystemPreferences_lockFile0;
text: .text%Java_java_io_UnixFileSystem_setLastModifiedTime;
-text: .text%Java_java_util_prefs_FileSystemPreferences_unlockFile0;
# Test LoadJFrame
text: .text%Java_sun_reflect_NativeMethodAccessorImpl_invoke0;
text: .text%Java_java_lang_Class_isInstance;
--- a/jdk/make/mapfiles/libjava/reorder-sparcv9 Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/mapfiles/libjava/reorder-sparcv9 Tue Mar 31 16:23:01 2015 -0700
@@ -1,7 +1,6 @@
data = R0x2000;
text = LOAD ?RXO;
# Test Null
-text: .text%init64IO: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%JNI_OnLoad;
text: .text%Canonicalize;
text: .text%canonicalize;
@@ -30,9 +29,9 @@
text: .text%Java_sun_reflect_Reflection_getCallerClass__I;
text: .text%Java_java_lang_Class_forName0;
text: .text%Java_java_lang_String_intern;
-text: .text%Java_java_lang_Float_floatToIntBits;
-text: .text%Java_java_lang_Double_doubleToLongBits;
-text: .text%Java_java_lang_ClassLoader_findLoadedClass;
+text: .text%Java_java_lang_Float_floatToRawIntBits;
+text: .text%Java_java_lang_Double_doubleToRawLongBits;
+text: .text%Java_java_lang_ClassLoader_findLoadedClass0;
text: .text%Java_java_lang_ClassLoader_findBootstrapClass;
text: .text%VerifyClassCodes;
text: .text%Java_java_lang_Throwable_fillInStackTrace;
@@ -41,10 +40,9 @@
text: .text%Java_java_lang_System_identityHashCode;
text: .text%Java_sun_misc_Signal_findSignal;
text: .text%Java_sun_misc_Signal_handle0;
-text: .text%Java_java_io_FileSystem_getFileSystem;
text: .text%JNU_NewObjectByName;
text: .text%Java_java_io_UnixFileSystem_initIDs;
-text: .text%Java_java_io_UnixFileSystem_canonicalize;
+text: .text%Java_java_io_UnixFileSystem_canonicalize0;
text: .text%JNU_GetStringPlatformChars;
text: .text%JNU_ReleaseStringPlatformChars;
text: .text%Java_java_io_FileInputStream_open0;
@@ -53,13 +51,11 @@
text: .text%readBytes;
text: .text%Java_java_io_FileInputStream_available;
text: .text%Java_java_io_FileInputStream_close0;
-text: .text%Java_java_lang_Compiler_registerNatives;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2;
text: .text%Java_java_io_UnixFileSystem_list;
text: .text%JNU_ClassString;
text: .text%JNU_CopyObjectArray;
text: .text%Java_java_io_UnixFileSystem_getBooleanAttributes0;
-text: .text%statMode: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2Ljava_security_AccessControlContext_2;
text: .text%Java_java_lang_System_mapLibraryName;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_load;
@@ -68,7 +64,7 @@
text: .text%Java_java_lang_Object_getClass;
text: .text%Java_java_lang_ClassLoader_defineClass0;
# Test Exit
-text: .text%Java_java_lang_Shutdown_halt;
+text: .text%Java_java_lang_Shutdown_halt0;
# Test Hello
text: .text%Java_java_io_FileOutputStream_writeBytes;
text: .text%writeBytes;
@@ -88,9 +84,7 @@
text: .text%JNU_CallMethodByNameV;
text: .text%Java_java_io_UnixFileSystem_createDirectory;
text: .text%Java_java_io_UnixFileSystem_getLastModifiedTime;
-text: .text%Java_java_util_prefs_FileSystemPreferences_lockFile0;
text: .text%Java_java_io_UnixFileSystem_setLastModifiedTime;
-text: .text%Java_java_util_prefs_FileSystemPreferences_unlockFile0;
# Test LoadJFrame
text: .text%Java_java_lang_Class_isAssignableFrom;
text: .text%Java_java_lang_Class_isInstance;
--- a/jdk/make/mapfiles/libjava/reorder-x86 Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/mapfiles/libjava/reorder-x86 Tue Mar 31 16:23:01 2015 -0700
@@ -2,7 +2,6 @@
text = LOAD ?RXO;
# Test Null
text: .text%_init;
-text: .text%init64IO: OUTPUTDIR/UnixFileSystem_md.o;
text: .text%JNI_OnLoad;
text: .text%Canonicalize;
text: .text%canonicalize;
@@ -36,8 +35,6 @@
text: .text%Java_java_lang_Throwable_fillInStackTrace;
text: .text%Java_java_lang_System_setOut0;
text: .text%Java_java_lang_System_setErr0;
-text: .text%Java_java_lang_Compiler_registerNatives;
-text: .text%Java_java_io_FileSystem_getFileSystem;
text: .text%JNU_NewObjectByName;
text: .text%Java_java_io_UnixFileSystem_initIDs;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2;
@@ -46,17 +43,17 @@
text: .text%JNU_ReleaseStringPlatformChars;
text: .text%JNU_ClassString;
text: .text%JNU_CopyObjectArray;
-text: .text%Java_java_io_UnixFileSystem_canonicalize;
+text: .text%Java_java_io_UnixFileSystem_canonicalize0;
text: .text%Java_java_io_UnixFileSystem_getBooleanAttributes0;
-text: .text%Java_java_lang_ClassLoader_findLoadedClass;
+text: .text%Java_java_lang_ClassLoader_findLoadedClass0;
text: .text%Java_java_lang_ClassLoader_findBootstrapClass;
text: .text%Java_java_security_AccessController_doPrivileged__Ljava_security_PrivilegedExceptionAction_2Ljava_security_AccessControlContext_2;
text: .text%Java_java_lang_System_mapLibraryName;
text: .text%cpchars: OUTPUTDIR/System.o;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_load;
text: .text%Java_java_lang_ClassLoader_00024NativeLibrary_find;
-text: .text%Java_java_lang_Float_floatToIntBits;
-text: .text%Java_java_lang_Double_doubleToLongBits;
+text: .text%Java_java_lang_Float_floatToRawIntBits;
+text: .text%Java_java_lang_Double_doubleToRawLongBits;
text: .text%Java_java_io_FileInputStream_open0;
text: .text%fileOpen;
text: .text%Java_java_io_UnixFileSystem_getLength;
@@ -67,7 +64,7 @@
text: .text%Java_java_lang_ClassLoader_defineClass0;
text: .text%VerifyClassCodes;
# Test Exit
-text: .text%Java_java_lang_Shutdown_halt;
+text: .text%Java_java_lang_Shutdown_halt0;
# Test Hello
text: .text%Java_java_io_FileOutputStream_writeBytes;
text: .text%writeBytes;
@@ -93,9 +90,7 @@
text: .text%Java_java_io_FileOutputStream_open0;
text: .text%Java_java_io_UnixFileSystem_createDirectory;
text: .text%Java_java_io_UnixFileSystem_getLastModifiedTime;
-text: .text%Java_java_util_prefs_FileSystemPreferences_lockFile0;
text: .text%Java_java_io_UnixFileSystem_setLastModifiedTime;
-text: .text%Java_java_util_prefs_FileSystemPreferences_unlockFile0;
text: .text%Java_java_io_FileOutputStream_close0;
text: .text%Java_java_util_logging_FileHandler_unlockFile;
# Test LoadJFrame
--- a/jdk/make/mapfiles/libzip/reorder-sparcv9 Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/mapfiles/libzip/reorder-sparcv9 Tue Mar 31 16:23:01 2015 -0700
@@ -12,7 +12,6 @@
text: .text%ZIP_FindEntry;
text: .text%ZIP_GetEntry;
text: .text%ZIP_Lock;
-text: .text%readLOC: OUTPUTDIR/zip_util.o;
text: .text%ZIP_Unlock;
text: .text%ZIP_FreeEntry;
text: .text%Java_java_util_zip_ZipFile_initIDs;
@@ -37,7 +36,6 @@
text: .text%inflate;
text: .text%Java_java_util_zip_ZipFile_read;
text: .text%ZIP_Read;
-text: .text%huft_build: OUTPUTDIR/inftrees.o;
text: .text%zcfree;
text: .text%Java_java_util_jar_JarFile_getMetaInfEntryNames;
text: .text%ZIP_ReadEntry;
--- a/jdk/make/mapfiles/libzip/reorder-x86 Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/make/mapfiles/libzip/reorder-x86 Tue Mar 31 16:23:01 2015 -0700
@@ -13,7 +13,6 @@
text: .text%ZIP_FindEntry;
text: .text%ZIP_GetEntry;
text: .text%ZIP_Lock;
-text: .text%readLOC: OUTPUTDIR/zip_util.o;
text: .text%ZIP_Unlock;
text: .text%ZIP_FreeEntry;
text: .text%Java_java_util_zip_ZipFile_initIDs;
@@ -38,7 +37,6 @@
text: .text%inflate;
text: .text%Java_java_util_zip_ZipFile_read;
text: .text%ZIP_Read;
-text: .text%huft_build: OUTPUTDIR/inftrees.o;
text: .text%zcfree;
text: .text%Java_java_util_jar_JarFile_getMetaInfEntryNames;
text: .text%ZIP_ReadEntry;
--- a/jdk/src/java.base/share/classes/com/sun/net/ssl/HttpsURLConnection.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/com/sun/net/ssl/HttpsURLConnection.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2015, 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
@@ -32,10 +32,10 @@
import java.net.URL;
import java.net.HttpURLConnection;
import java.io.IOException;
+import java.security.cert.Certificate;
import javax.net.SocketFactory;
import javax.net.ssl.SSLSocketFactory;
-
-import javax.security.cert.X509Certificate;
+import javax.net.ssl.SSLPeerUnverifiedException;
/**
* HTTP URL connection with support for HTTPS-specific features. See
@@ -70,7 +70,8 @@
* the server did not authenticate.
* @return the server certificate chain
*/
- public abstract X509Certificate [] getServerCertificateChain();
+ public abstract Certificate[] getServerCertificates()
+ throws SSLPeerUnverifiedException;
/**
* HostnameVerifier provides a callback mechanism so that
--- a/jdk/src/java.base/share/classes/com/sun/net/ssl/internal/www/protocol/https/HttpsURLConnectionOldImpl.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/com/sun/net/ssl/internal/www/protocol/https/HttpsURLConnectionOldImpl.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2015, 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
@@ -187,25 +187,6 @@
return delegate.getServerCertificates();
}
- /**
- * Returns the server's X.509 certificate chain, or null if
- * the server did not authenticate.
- *
- * NOTE: This method is not necessary for the version of this class
- * implementing javax.net.ssl.HttpsURLConnection, but provided for
- * compatibility with the com.sun.net.ssl.HttpsURLConnection version.
- */
- public javax.security.cert.X509Certificate[] getServerCertificateChain() {
- try {
- return delegate.getServerCertificateChain();
- } catch (SSLPeerUnverifiedException e) {
- // this method does not throw an exception as declared in
- // com.sun.net.ssl.HttpsURLConnection.
- // Return null for compatibility.
- return null;
- }
- }
-
/*
* Allowable input/output sequences:
* [interpreted as POST/PUT]
--- a/jdk/src/java.base/share/classes/java/io/ObjectStreamException.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/io/ObjectStreamException.java Tue Mar 31 16:23:01 2015 -0700
@@ -38,10 +38,10 @@
/**
* Create an ObjectStreamException with the specified argument.
*
- * @param classname the detailed message for the exception
+ * @param message the detailed message for the exception
*/
- protected ObjectStreamException(String classname) {
- super(classname);
+ protected ObjectStreamException(String message) {
+ super(message);
}
/**
--- a/jdk/src/java.base/share/classes/java/net/ProtocolException.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/net/ProtocolException.java Tue Mar 31 16:23:01 2015 -0700
@@ -42,10 +42,10 @@
* Constructs a new {@code ProtocolException} with the
* specified detail message.
*
- * @param host the detail message.
+ * @param message the detail message.
*/
- public ProtocolException(String host) {
- super(host);
+ public ProtocolException(String message) {
+ super(message);
}
/**
--- a/jdk/src/java.base/share/classes/java/net/UnknownHostException.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/net/UnknownHostException.java Tue Mar 31 16:23:01 2015 -0700
@@ -41,10 +41,10 @@
* Constructs a new {@code UnknownHostException} with the
* specified detail message.
*
- * @param host the detail message.
+ * @param message the detail message.
*/
- public UnknownHostException(String host) {
- super(host);
+ public UnknownHostException(String message) {
+ super(message);
}
/**
--- a/jdk/src/java.base/share/classes/java/util/Calendar.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/util/Calendar.java Tue Mar 31 16:23:01 2015 -0700
@@ -2083,17 +2083,33 @@
return null;
}
+ String calendarType = getCalendarType();
+ int fieldValue = get(field);
// the standalone and narrow styles are supported only through CalendarDataProviders.
- if (isStandaloneStyle(style) || isNarrowStyle(style)) {
- return CalendarDataUtility.retrieveFieldValueName(getCalendarType(),
- field, get(field),
- style, locale);
+ if (isStandaloneStyle(style) || isNarrowFormatStyle(style)) {
+ String val = CalendarDataUtility.retrieveFieldValueName(calendarType,
+ field, fieldValue,
+ style, locale);
+ // Perform fallback here to follow the CLDR rules
+ if (val == null) {
+ if (isNarrowFormatStyle(style)) {
+ val = CalendarDataUtility.retrieveFieldValueName(calendarType,
+ field, fieldValue,
+ toStandaloneStyle(style),
+ locale);
+ } else if (isStandaloneStyle(style)) {
+ val = CalendarDataUtility.retrieveFieldValueName(calendarType,
+ field, fieldValue,
+ getBaseStyle(style),
+ locale);
+ }
+ }
+ return val;
}
DateFormatSymbols symbols = DateFormatSymbols.getInstance(locale);
String[] strings = getFieldStrings(field, style, symbols);
if (strings != null) {
- int fieldValue = get(field);
if (fieldValue < strings.length) {
return strings[fieldValue];
}
@@ -2155,10 +2171,26 @@
ERA_MASK|MONTH_MASK|DAY_OF_WEEK_MASK|AM_PM_MASK)) {
return null;
}
- if (style == ALL_STYLES || isStandaloneStyle(style)) {
- return CalendarDataUtility.retrieveFieldValueNames(getCalendarType(), field, style, locale);
+
+ String calendarType = getCalendarType();
+ if (style == ALL_STYLES || isStandaloneStyle(style) || isNarrowFormatStyle(style)) {
+ Map<String, Integer> map;
+ map = CalendarDataUtility.retrieveFieldValueNames(calendarType, field, style, locale);
+
+ // Perform fallback here to follow the CLDR rules
+ if (map == null) {
+ if (isNarrowFormatStyle(style)) {
+ map = CalendarDataUtility.retrieveFieldValueNames(calendarType, field,
+ toStandaloneStyle(style), locale);
+ } else if (style != ALL_STYLES) {
+ map = CalendarDataUtility.retrieveFieldValueNames(calendarType, field,
+ getBaseStyle(style), locale);
+ }
+ }
+ return map;
}
- // SHORT, LONG, or NARROW
+
+ // SHORT or LONG
return getDisplayNamesImpl(field, style, locale);
}
@@ -2544,14 +2576,22 @@
return style & ~STANDALONE_MASK;
}
- boolean isStandaloneStyle(int style) {
+ private int toStandaloneStyle(int style) {
+ return style | STANDALONE_MASK;
+ }
+
+ private boolean isStandaloneStyle(int style) {
return (style & STANDALONE_MASK) != 0;
}
- boolean isNarrowStyle(int style) {
+ private boolean isNarrowStyle(int style) {
return style == NARROW_FORMAT || style == NARROW_STANDALONE;
}
+ private boolean isNarrowFormatStyle(int style) {
+ return style == NARROW_FORMAT;
+ }
+
/**
* Returns the pseudo-time-stamp for two fields, given their
* individual pseudo-time-stamps. If either of the fields
--- a/jdk/src/java.base/share/classes/java/util/stream/AbstractPipeline.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/util/stream/AbstractPipeline.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2015, 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
@@ -380,60 +380,6 @@
}
/**
- * Prepare the pipeline for a parallel execution. As the pipeline is built,
- * the flags and depth indicators are set up for a sequential execution.
- * If the execution is parallel, and there are any stateful operations, then
- * some of these need to be adjusted, as well as adjusting for flags from
- * the terminal operation (such as back-propagating UNORDERED).
- * Need not be called for a sequential execution.
- *
- * @param terminalFlags Operation flags for the terminal operation
- */
- private void parallelPrepare(int terminalFlags) {
- @SuppressWarnings("rawtypes")
- AbstractPipeline backPropagationHead = sourceStage;
- if (sourceStage.sourceAnyStateful) {
- int depth = 1;
- for ( @SuppressWarnings("rawtypes") AbstractPipeline u = sourceStage, p = sourceStage.nextStage;
- p != null;
- u = p, p = p.nextStage) {
- int thisOpFlags = p.sourceOrOpFlags;
- if (p.opIsStateful()) {
- // If the stateful operation is a short-circuit operation
- // then move the back propagation head forwards
- // NOTE: there are no size-injecting ops
- if (StreamOpFlag.SHORT_CIRCUIT.isKnown(thisOpFlags)) {
- backPropagationHead = p;
- // Clear the short circuit flag for next pipeline stage
- // This stage encapsulates short-circuiting, the next
- // stage may not have any short-circuit operations, and
- // if so spliterator.forEachRemaining should be used
- // for traversal
- thisOpFlags = thisOpFlags & ~StreamOpFlag.IS_SHORT_CIRCUIT;
- }
-
- depth = 0;
- // The following injects size, it is equivalent to:
- // StreamOpFlag.combineOpFlags(StreamOpFlag.IS_SIZED, p.combinedFlags);
- thisOpFlags = (thisOpFlags & ~StreamOpFlag.NOT_SIZED) | StreamOpFlag.IS_SIZED;
- }
- p.depth = depth++;
- p.combinedFlags = StreamOpFlag.combineOpFlags(thisOpFlags, u.combinedFlags);
- }
- }
-
- // Apply the upstream terminal flags
- if (terminalFlags != 0) {
- int upstreamTerminalFlags = terminalFlags & StreamOpFlag.UPSTREAM_TERMINAL_OP_MASK;
- for ( @SuppressWarnings("rawtypes") AbstractPipeline p = backPropagationHead; p.nextStage != null; p = p.nextStage) {
- p.combinedFlags = StreamOpFlag.combineOpFlags(upstreamTerminalFlags, p.combinedFlags);
- }
-
- combinedFlags = StreamOpFlag.combineOpFlags(terminalFlags, combinedFlags);
- }
- }
-
- /**
* Get the source spliterator for this pipeline stage. For a sequential or
* stateless parallel pipeline, this is the source spliterator. For a
* stateful parallel pipeline, this is a spliterator describing the results
@@ -456,24 +402,70 @@
throw new IllegalStateException(MSG_CONSUMED);
}
- if (isParallel()) {
- // @@@ Merge parallelPrepare with the loop below and use the
- // spliterator characteristics to determine if SIZED
- // should be injected
- parallelPrepare(terminalFlags);
+ boolean hasTerminalFlags = terminalFlags != 0;
+ if (isParallel() && sourceStage.sourceAnyStateful) {
+ // Adjust pipeline stages if there are stateful ops,
+ // and find the last short circuiting op, if any, that
+ // defines the head stage for back-propagation of terminal flags
+ @SuppressWarnings("rawtypes")
+ AbstractPipeline backPropagationHead = sourceStage;
+ int depth = 1;
+ for (@SuppressWarnings("rawtypes") AbstractPipeline p = sourceStage.nextStage;
+ p != null;
+ p = p.nextStage) {
+ if (p.opIsStateful()) {
+ if (StreamOpFlag.SHORT_CIRCUIT.isKnown(p.sourceOrOpFlags)) {
+ // If the stateful operation is a short-circuit operation
+ // then move the back propagation head forwards
+ // NOTE: there are no size-injecting ops
+ backPropagationHead = p;
+ }
+
+ depth = 0;
+ }
+ p.depth = depth++;
+ }
// Adapt the source spliterator, evaluating each stateful op
// in the pipeline up to and including this pipeline stage
- for ( @SuppressWarnings("rawtypes") AbstractPipeline u = sourceStage, p = sourceStage.nextStage, e = this;
+ // Flags for each pipeline stage are adjusted accordingly
+ boolean backPropagate = false;
+ int upstreamTerminalFlags = terminalFlags & StreamOpFlag.UPSTREAM_TERMINAL_OP_MASK;
+ for (@SuppressWarnings("rawtypes") AbstractPipeline u = sourceStage, p = sourceStage.nextStage, e = this;
u != e;
u = p, p = p.nextStage) {
+ if (hasTerminalFlags &&
+ (backPropagate || (backPropagate = (u == backPropagationHead)))) {
+ // Back-propagate flags from the terminal operation
+ u.combinedFlags = StreamOpFlag.combineOpFlags(upstreamTerminalFlags, u.combinedFlags);
+ }
+
+ int thisOpFlags = p.sourceOrOpFlags;
if (p.opIsStateful()) {
+ if (StreamOpFlag.SHORT_CIRCUIT.isKnown(thisOpFlags)) {
+ // Clear the short circuit flag for next pipeline stage
+ // This stage encapsulates short-circuiting, the next
+ // stage may not have any short-circuit operations, and
+ // if so spliterator.forEachRemaining should be used
+ // for traversal
+ thisOpFlags = thisOpFlags & ~StreamOpFlag.IS_SHORT_CIRCUIT;
+ }
+
spliterator = p.opEvaluateParallelLazy(u, spliterator);
+
+ // Inject or clear SIZED on the source pipeline stage
+ // based on the stage's spliterator
+ thisOpFlags = spliterator.hasCharacteristics(Spliterator.SIZED)
+ ? (thisOpFlags & ~StreamOpFlag.NOT_SIZED) | StreamOpFlag.IS_SIZED
+ : (thisOpFlags & ~StreamOpFlag.IS_SIZED) | StreamOpFlag.NOT_SIZED;
}
+ p.combinedFlags = StreamOpFlag.combineOpFlags(thisOpFlags, u.combinedFlags);
}
}
- else if (terminalFlags != 0) {
+
+ if (hasTerminalFlags) {
+ // Apply flags from the terminal operation to last pipeline stage
combinedFlags = StreamOpFlag.combineOpFlags(terminalFlags, combinedFlags);
}
--- a/jdk/src/java.base/share/classes/java/util/stream/ReduceOps.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/java/util/stream/ReduceOps.java Tue Mar 31 16:23:01 2015 -0700
@@ -264,6 +264,11 @@
return spliterator.getExactSizeIfKnown();
return super.evaluateParallel(helper, spliterator);
}
+
+ @Override
+ public int getOpFlags() {
+ return StreamOpFlag.NOT_ORDERED;
+ }
};
}
@@ -433,6 +438,11 @@
return spliterator.getExactSizeIfKnown();
return super.evaluateParallel(helper, spliterator);
}
+
+ @Override
+ public int getOpFlags() {
+ return StreamOpFlag.NOT_ORDERED;
+ }
};
}
@@ -602,6 +612,11 @@
return spliterator.getExactSizeIfKnown();
return super.evaluateParallel(helper, spliterator);
}
+
+ @Override
+ public int getOpFlags() {
+ return StreamOpFlag.NOT_ORDERED;
+ }
};
}
@@ -771,6 +786,11 @@
return spliterator.getExactSizeIfKnown();
return super.evaluateParallel(helper, spliterator);
}
+
+ @Override
+ public int getOpFlags() {
+ return StreamOpFlag.NOT_ORDERED;
+ }
};
}
--- a/jdk/src/java.base/share/classes/sun/misc/Unsafe.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/misc/Unsafe.java Tue Mar 31 16:23:01 2015 -0700
@@ -631,6 +631,10 @@
/**
* Atomically updates Java variable to {@code x} if it is currently
* holding {@code expected}.
+ *
+ * <p>This operation has memory semantics of a {@code volatile} read
+ * and write. Corresponds to C11 atomic_compare_exchange_strong.
+ *
* @return {@code true} if successful
*/
public final native boolean compareAndSwapObject(Object o, long offset,
@@ -640,6 +644,10 @@
/**
* Atomically updates Java variable to {@code x} if it is currently
* holding {@code expected}.
+ *
+ * <p>This operation has memory semantics of a {@code volatile} read
+ * and write. Corresponds to C11 atomic_compare_exchange_strong.
+ *
* @return {@code true} if successful
*/
public final native boolean compareAndSwapInt(Object o, long offset,
@@ -649,6 +657,10 @@
/**
* Atomically updates Java variable to {@code x} if it is currently
* holding {@code expected}.
+ *
+ * <p>This operation has memory semantics of a {@code volatile} read
+ * and write. Corresponds to C11 atomic_compare_exchange_strong.
+ *
* @return {@code true} if successful
*/
public final native boolean compareAndSwapLong(Object o, long offset,
--- a/jdk/src/java.base/share/classes/sun/net/www/protocol/https/AbstractDelegateHttpsURLConnection.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/net/www/protocol/https/AbstractDelegateHttpsURLConnection.java Tue Mar 31 16:23:01 2015 -0700
@@ -262,27 +262,6 @@
}
/**
- * Returns the server's X.509 certificate chain, or null if
- * the server did not authenticate.
- *
- * @deprecated This method returns the deprecated
- * {@code javax.security.cert.X509Certificate} type.
- * Use {@code getServerCertificates()} instead.
- */
- @Deprecated
- public javax.security.cert.X509Certificate[] getServerCertificateChain()
- throws SSLPeerUnverifiedException {
- if (cachedResponse != null) {
- throw new UnsupportedOperationException("this method is not supported when using cache");
- }
- if (http == null) {
- throw new IllegalStateException("connection not yet open");
- } else {
- return ((HttpsClient)http).getServerCertificateChain();
- }
- }
-
- /**
* Returns the server's principal, or throws SSLPeerUnverifiedException
* if the server did not authenticate.
*/
--- a/jdk/src/java.base/share/classes/sun/net/www/protocol/https/HttpsClient.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/net/www/protocol/https/HttpsClient.java Tue Mar 31 16:23:01 2015 -0700
@@ -697,21 +697,6 @@
}
/**
- * Returns the X.509 certificate chain with which the server
- * authenticated itself, or null if the server did not authenticate.
- *
- * @deprecated This method returns the deprecated
- * {@code javax.security.cert.X509Certificate} type.
- * Use {@code getServerCertificates()} instead.
- */
- @Deprecated
- javax.security.cert.X509Certificate [] getServerCertificateChain()
- throws SSLPeerUnverifiedException
- {
- return session.getPeerCertificateChain();
- }
-
- /**
* Returns the principal with which the server authenticated
* itself, or throw a SSLPeerUnverifiedException if the
* server did not authenticate.
--- a/jdk/src/java.base/share/classes/sun/net/www/protocol/https/HttpsURLConnectionImpl.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/net/www/protocol/https/HttpsURLConnectionImpl.java Tue Mar 31 16:23:01 2015 -0700
@@ -198,30 +198,6 @@
}
/**
- * Returns the server's X.509 certificate chain, or null if
- * the server did not authenticate.
- *
- * NOTE: This method is not necessary for the version of this class
- * implementing javax.net.ssl.HttpsURLConnection, but provided for
- * compatibility with the com.sun.net.ssl.HttpsURLConnection version.
- *
- * @deprecated This method returns the deprecated
- * {@code javax.security.cert.X509Certificate} type.
- * Use {@code getServerCertificates()} instead.
- */
- @Deprecated
- public javax.security.cert.X509Certificate[] getServerCertificateChain() {
- try {
- return delegate.getServerCertificateChain();
- } catch (SSLPeerUnverifiedException e) {
- // this method does not throw an exception as declared in
- // com.sun.net.ssl.HttpsURLConnection.
- // Return null for compatibility.
- return null;
- }
- }
-
- /**
* Returns the principal with which the server authenticated itself,
* or throw a SSLPeerUnverifiedException if the server did not authenticate.
*/
--- a/jdk/src/java.base/share/classes/sun/reflect/misc/FieldUtil.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/reflect/misc/FieldUtil.java Tue Mar 31 16:23:01 2015 -0700
@@ -45,9 +45,4 @@
ReflectUtil.checkPackageAccess(cls);
return cls.getFields();
}
-
- public static Field[] getDeclaredFields(Class<?> cls) {
- ReflectUtil.checkPackageAccess(cls);
- return cls.getDeclaredFields();
- }
}
--- a/jdk/src/java.base/share/classes/sun/util/calendar/ZoneInfoFile.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/classes/sun/util/calendar/ZoneInfoFile.java Tue Mar 31 16:23:01 2015 -0700
@@ -625,6 +625,15 @@
params[2] = 5;
params[3] = 86400000;
}
+ // Additional check for startDayOfWeek=6 and starTime=86400000
+ // is needed for Asia/Amman; Asia/Gasa and Asia/Hebron
+ if (params[2] == 7 && params[3] == 0 &&
+ (zoneId.equals("Asia/Amman") ||
+ zoneId.equals("Asia/Gaza") ||
+ zoneId.equals("Asia/Hebron"))) {
+ params[2] = 6; // Friday
+ params[3] = 86400000; // 24h
+ }
//endDayOfWeek and endTime workaround
if (params[7] == 6 && params[8] == 0 &&
(zoneId.equals("Africa/Cairo"))) {
--- a/jdk/src/java.base/share/native/libjli/manifest_info.h Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/native/libjli/manifest_info.h Tue Mar 31 16:23:01 2015 -0700
@@ -109,6 +109,8 @@
/*
* Macros for getting end of central directory header (END) fields
*/
+#define ENDNMD(b) SH(b, 4) /* number of this disk */
+#define ENDDSK(b) SH(b, 6) /* disk number of start */
#define ENDSUB(b) SH(b, 8) /* number of entries on this disk */
#define ENDTOT(b) SH(b, 10) /* total number of entries */
#define ENDSIZ(b) LG(b, 12) /* central directory size */
--- a/jdk/src/java.base/share/native/libjli/parse_manifest.c Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/share/native/libjli/parse_manifest.c Tue Mar 31 16:23:01 2015 -0700
@@ -111,52 +111,127 @@
return (NULL);
}
-static jboolean zip64_present = JNI_FALSE;
+/*
+ * Implementation notes:
+ *
+ * This is a zip format reader for seekable files, that tolerates
+ * leading and trailing garbage, and tolerates having had internal
+ * offsets adjusted for leading garbage (as with Info-Zip's zip -A).
+ *
+ * We find the end header by scanning backwards from the end of the
+ * file for the end signature. This may fail in the presence of
+ * trailing garbage or a ZIP file comment that contains binary data.
+ * Similarly, the ZIP64 end header may need to be located by scanning
+ * backwards from the end header. It may be misidentified, but this
+ * is very unlikely to happen in practice without adversarial input.
+ *
+ * The zip file format is documented at:
+ * https://www.pkware.com/documents/casestudies/APPNOTE.TXT
+ *
+ * TODO: more informative error messages
+ */
+
+/** Reads count bytes from fd at position pos into given buffer. */
+static jboolean
+readAt(int fd, jlong pos, size_t count, void *buf) {
+ return (pos >= 0
+ && JLI_Lseek(fd, pos, SEEK_SET) == pos
+ && read(fd, buf, count) == (jlong) count);
+}
+
/*
- * Checks to see if we have ZIP64 archive, and save
- * the check for later use
+ * Tells whether given header values (obtained from either ZIP64 or
+ * non-ZIP64 header) appear to be correct, by checking the first LOC
+ * and CEN headers.
*/
-static int
-haveZIP64(Byte *p) {
- jlong cenlen, cenoff, centot;
- cenlen = ENDSIZ(p);
- cenoff = ENDOFF(p);
- centot = ENDTOT(p);
- zip64_present = (cenlen == ZIP64_MAGICVAL ||
- cenoff == ZIP64_MAGICVAL ||
- centot == ZIP64_MAGICCOUNT);
- return zip64_present;
-}
-
-static jlong
-find_end64(int fd, Byte *ep, jlong pos)
-{
- jlong end64pos;
- jlong bytes;
- if ((end64pos = JLI_Lseek(fd, pos - ZIP64_LOCHDR, SEEK_SET)) < (jlong)0)
- return -1;
- if ((bytes = read(fd, ep, ZIP64_LOCHDR)) < 0)
- return -1;
- if (ZIP64_LOCSIG_AT(ep))
- return end64pos;
- return -1;
+static jboolean
+is_valid_end_header(int fd, jlong endpos,
+ jlong censiz, jlong cenoff, jlong entries) {
+ Byte cenhdr[CENHDR];
+ Byte lochdr[LOCHDR];
+ // Expected offset of the first central directory header
+ jlong censtart = endpos - censiz;
+ // Expected position within the file that offsets are relative to
+ jlong base_offset = endpos - (censiz + cenoff);
+ return censtart >= 0 && cenoff >= 0 &&
+ (censiz == 0 ||
+ // Validate first CEN and LOC header signatures.
+ // Central directory must come directly before the end header.
+ (readAt(fd, censtart, CENHDR, cenhdr)
+ && CENSIG_AT(cenhdr)
+ && readAt(fd, base_offset + CENOFF(cenhdr), LOCHDR, lochdr)
+ && LOCSIG_AT(lochdr)
+ && CENNAM(cenhdr) == LOCNAM(lochdr)));
}
/*
- * A very little used routine to handle the case that zip file has
- * a comment at the end. Believe it or not, the only way to find the
- * END record is to walk backwards, byte by bloody byte looking for
- * the END record signature.
+ * Tells whether p appears to be pointing at a valid ZIP64 end header.
+ * Values censiz, cenoff, and entries are the corresponding values
+ * from the non-ZIP64 end header. We perform extra checks to avoid
+ * misidentifying data from the last entry as a ZIP64 end header.
+ */
+static jboolean
+is_zip64_endhdr(int fd, const Byte *p, jlong end64pos,
+ jlong censiz, jlong cenoff, jlong entries) {
+ if (ZIP64_ENDSIG_AT(p)) {
+ jlong censiz64 = ZIP64_ENDSIZ(p);
+ jlong cenoff64 = ZIP64_ENDOFF(p);
+ jlong entries64 = ZIP64_ENDTOT(p);
+ return (censiz64 == censiz || censiz == ZIP64_MAGICVAL)
+ && (cenoff64 == cenoff || cenoff == ZIP64_MAGICVAL)
+ && (entries64 == entries || entries == ZIP64_MAGICCOUNT)
+ && is_valid_end_header(fd, end64pos, censiz64, cenoff64, entries64);
+ }
+ return JNI_FALSE;
+}
+
+/*
+ * Given a non-ZIP64 end header located at endhdr and endpos, look for
+ * an adjacent ZIP64 end header, finding the base offset and censtart
+ * from the ZIP64 header if available, else from the non-ZIP64 header.
+ * @return 0 if successful, -1 in case of failure
+ */
+static int
+find_positions64(int fd, const Byte * const endhdr, const jlong endpos,
+ jlong* base_offset, jlong* censtart)
+{
+ jlong censiz = ENDSIZ(endhdr);
+ jlong cenoff = ENDOFF(endhdr);
+ jlong entries = ENDTOT(endhdr);
+ jlong end64pos;
+ Byte buf[ZIP64_ENDHDR + ZIP64_LOCHDR];
+ if (censiz + cenoff != endpos
+ && (end64pos = endpos - sizeof(buf)) >= (jlong)0
+ && readAt(fd, end64pos, sizeof(buf), buf)
+ && ZIP64_LOCSIG_AT(buf + ZIP64_ENDHDR)
+ && (jlong) ZIP64_LOCDSK(buf + ZIP64_ENDHDR) == ENDDSK(endhdr)
+ && (is_zip64_endhdr(fd, buf, end64pos, censiz, cenoff, entries)
+ || // A variable sized "zip64 extensible data sector" ?
+ ((end64pos = ZIP64_LOCOFF(buf + ZIP64_ENDHDR)) >= (jlong)0
+ && readAt(fd, end64pos, ZIP64_ENDHDR, buf)
+ && is_zip64_endhdr(fd, buf, end64pos, censiz, cenoff, entries)))
+ ) {
+ *censtart = end64pos - ZIP64_ENDSIZ(buf);
+ *base_offset = *censtart - ZIP64_ENDOFF(buf);
+ } else {
+ if (!is_valid_end_header(fd, endpos, censiz, cenoff, entries))
+ return -1;
+ *censtart = endpos - censiz;
+ *base_offset = *censtart - cenoff;
+ }
+ return 0;
+}
+
+/*
+ * Finds the base offset and censtart of the zip file.
*
- * fd: File descriptor of the jar file.
- * eb: Pointer to a buffer to receive a copy of the END header.
- *
- * Returns the offset of the END record in the file on success,
- * -1 on failure.
+ * @param fd file descriptor of the jar file
+ * @param eb scratch buffer
+ * @return 0 if successful, -1 in case of failure
*/
-static jlong
-find_end(int fd, Byte *eb)
+static int
+find_positions(int fd, Byte *eb, jlong* base_offset, jlong* censtart)
{
jlong len;
jlong pos;
@@ -177,7 +252,7 @@
if ((bytes = read(fd, eb, ENDHDR)) < 0)
return (-1);
if (ENDSIG_AT(eb)) {
- return haveZIP64(eb) ? find_end64(fd, eb, pos) : pos;
+ return find_positions64(fd, eb, pos, base_offset, censtart);
}
/*
@@ -208,7 +283,7 @@
(void) memcpy(eb, cp, ENDHDR);
free(buffer);
pos = flen - (endpos - cp);
- return haveZIP64(eb) ? find_end64(fd, eb, pos) : pos;
+ return find_positions64(fd, eb, pos, base_offset, censtart);
}
free(buffer);
return (-1);
@@ -218,82 +293,6 @@
#define MINREAD 1024
/*
- * Computes and positions at the start of the CEN header, ie. the central
- * directory, this will also return the offset if there is a zip file comment
- * at the end of the archive, for most cases this would be 0.
- */
-static jlong
-compute_cen(int fd, Byte *bp)
-{
- int bytes;
- Byte *p;
- jlong base_offset;
- jlong offset;
- char buffer[MINREAD];
- p = (Byte*) buffer;
- /*
- * Read the END Header, which is the starting point for ZIP files.
- * (Clearly designed to make writing a zip file easier than reading
- * one. Now isn't that precious...)
- */
- if ((base_offset = find_end(fd, bp)) == -1) {
- return (-1);
- }
- p = bp;
- /*
- * There is a historical, but undocumented, ability to allow for
- * additional "stuff" to be prepended to the zip/jar file. It seems
- * that this has been used to prepend an actual java launcher
- * executable to the jar on Windows. Although this is just another
- * form of statically linking a small piece of the JVM to the
- * application, we choose to continue to support it. Note that no
- * guarantees have been made (or should be made) to the customer that
- * this will continue to work.
- *
- * Therefore, calculate the base offset of the zip file (within the
- * expanded file) by assuming that the central directory is followed
- * immediately by the end record.
- */
- if (zip64_present) {
- if ((offset = ZIP64_LOCOFF(p)) < (jlong)0) {
- return -1;
- }
- if (JLI_Lseek(fd, offset, SEEK_SET) < (jlong) 0) {
- return (-1);
- }
- if ((bytes = read(fd, buffer, MINREAD)) < 0) {
- return (-1);
- }
- if (!ZIP64_ENDSIG_AT(buffer)) {
- return -1;
- }
- if ((offset = ZIP64_ENDOFF(buffer)) < (jlong)0) {
- return -1;
- }
- if (JLI_Lseek(fd, offset, SEEK_SET) < (jlong)0) {
- return (-1);
- }
- p = (Byte*) buffer;
- base_offset = base_offset - ZIP64_ENDSIZ(p) - ZIP64_ENDOFF(p) - ZIP64_ENDHDR;
- } else {
- base_offset = base_offset - ENDSIZ(p) - ENDOFF(p);
- /*
- * The END Header indicates the start of the Central Directory
- * Headers. Remember that the desired Central Directory Header (CEN)
- * will almost always be the second one and the first one is a small
- * directory entry ("META-INF/"). Keep the code optimized for
- * that case.
- *
- * Seek to the beginning of the Central Directory.
- */
- if (JLI_Lseek(fd, base_offset + ENDOFF(p), SEEK_SET) < (jlong) 0) {
- return (-1);
- }
- }
- return base_offset;
-}
-
-/*
* Locate the manifest file with the zip/jar file.
*
* fd: File descriptor of the jar file.
@@ -327,7 +326,23 @@
int res;
int entry_size;
int read_size;
+
+ /*
+ * The (imaginary) position within the file relative to which
+ * offsets within the zip file refer. This is usually the
+ * location of the first local header (the start of the zip data)
+ * (which in turn is usually 0), but if the zip file has content
+ * prepended, then it will be either 0 or the length of the
+ * prepended content, depending on whether or not internal offsets
+ * have been adjusted (via e.g. zip -A). May be negative if
+ * content is prepended, zip -A is run, then the prefix is
+ * detached!
+ */
jlong base_offset;
+
+ /** The position within the file of the start of the central directory. */
+ jlong censtart;
+
Byte *p;
Byte *bp;
Byte *buffer;
@@ -338,9 +353,11 @@
}
bp = buffer;
- base_offset = compute_cen(fd, bp);
- if (base_offset == -1) {
- free(buffer);
+
+ if (find_positions(fd, bp, &base_offset, &censtart) == -1) {
+ return -1;
+ }
+ if (JLI_Lseek(fd, censtart, SEEK_SET) < (jlong) 0) {
return -1;
}
--- a/jdk/src/java.base/unix/classes/java/lang/ProcessImpl.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/unix/classes/java/lang/ProcessImpl.java Tue Mar 31 16:23:01 2015 -0700
@@ -285,8 +285,6 @@
* 1 - fork(2) and exec(2)
* 2 - posix_spawn(3P)
* 3 - vfork(2) and exec(2)
- *
- * (4 - clone(2) and exec(2) - obsolete and currently disabled in native code)
* </pre>
* @param fds an array of three file descriptors.
* Indexes 0, 1, and 2 correspond to standard input,
--- a/jdk/src/java.base/unix/conf/arm/jvm.cfg Tue Mar 31 08:48:53 2015 -0700
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-# Copyright (c) 2011, 2013, 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.
-#
-# List of JVMs that can be used as an option to java, javac, etc.
-# Order is important -- first in this list is the default JVM.
-# NOTE that this both this file and its format are UNSUPPORTED and
-# WILL GO AWAY in a future release.
-#
-# You may also select a JVM in an arbitrary location with the
-# "-XXaltjvm=<jvm_dir>" option, but that too is unsupported
-# and may not be available in a future release.
-#
--client IF_SERVER_CLASS -server
--server KNOWN
--minimal KNOWN
--- a/jdk/src/java.base/unix/conf/ppc/jvm.cfg Tue Mar 31 08:48:53 2015 -0700
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-# Copyright (c) 2011, 2013, 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.
-#
-# List of JVMs that can be used as an option to java, javac, etc.
-# Order is important -- first in this list is the default JVM.
-# NOTE that this both this file and its format are UNSUPPORTED and
-# WILL GO AWAY in a future release.
-#
-# You may also select a JVM in an arbitrary location with the
-# "-XXaltjvm=<jvm_dir>" option, but that too is unsupported
-# and may not be available in a future release.
-#
--client KNOWN
--server KNOWN
--minimal KNOWN
--- a/jdk/src/java.base/unix/native/libjava/ProcessImpl_md.c Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/unix/native/libjava/ProcessImpl_md.c Tue Mar 31 16:23:01 2015 -0700
@@ -97,8 +97,7 @@
* address space temporarily, before launching the target command.
*
* Based on the above analysis, we are currently using vfork() on
- * Linux and spawn() on other Unix systems, but the code to use clone()
- * and fork() remains.
+ * Linux and posix_spawn() on other Unix systems.
*/
@@ -385,39 +384,13 @@
}
/**
- * We are unusually paranoid; use of clone/vfork is
+ * We are unusually paranoid; use of vfork is
* especially likely to tickle gcc/glibc bugs.
*/
#ifdef __attribute_noinline__ /* See: sys/cdefs.h */
__attribute_noinline__
#endif
-#define START_CHILD_USE_CLONE 0 /* clone() currently disabled; see above. */
-
-#ifdef START_CHILD_USE_CLONE
-static pid_t
-cloneChild(ChildStuff *c) {
-#ifdef __linux__
-#define START_CHILD_CLONE_STACK_SIZE (64 * 1024)
- /*
- * See clone(2).
- * Instead of worrying about which direction the stack grows, just
- * allocate twice as much and start the stack in the middle.
- */
- if ((c->clone_stack = malloc(2 * START_CHILD_CLONE_STACK_SIZE)) == NULL)
- /* errno will be set to ENOMEM */
- return -1;
- return clone(childProcess,
- c->clone_stack + START_CHILD_CLONE_STACK_SIZE,
- CLONE_VFORK | CLONE_VM | SIGCHLD, c);
-#else
-/* not available on Solaris / Mac */
- assert(0);
- return -1;
-#endif
-}
-#endif
-
static pid_t
vforkChild(ChildStuff *c) {
volatile pid_t resultPid;
@@ -590,12 +563,11 @@
c->argv = NULL;
c->envv = NULL;
c->pdir = NULL;
- c->clone_stack = NULL;
/* Convert prog + argBlock into a char ** argv.
* Add one word room for expansion of argv for use by
* execve_as_traditional_shell_script.
- * This word is also used when using spawn mode
+ * This word is also used when using posix_spawn mode
*/
assert(prog != NULL && argBlock != NULL);
if ((phelperpath = getBytes(env, helperpath)) == NULL) goto Catch;
@@ -654,7 +626,7 @@
throwIOException(env, errno, "fork failed");
break;
case MODE_POSIX_SPAWN:
- throwIOException(env, errno, "spawn failed");
+ throwIOException(env, errno, "posix_spawn failed");
break;
}
goto Catch;
@@ -677,8 +649,6 @@
fds[2] = (err[0] != -1) ? err[0] : -1;
Finally:
- free(c->clone_stack);
-
/* Always clean up the child's side of the pipes */
closeSafely(in [0]);
closeSafely(out[1]);
--- a/jdk/src/java.base/unix/native/libjava/childproc.c Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/unix/native/libjava/childproc.c Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2015, 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
@@ -304,7 +304,7 @@
}
/**
- * Child process after a successful fork() or clone().
+ * Child process after a successful fork().
* This function must not return, and must be prepared for either all
* of its address space to be shared with its parent, or to be a copy.
* It must not modify global variables such as "environ".
--- a/jdk/src/java.base/unix/native/libjava/childproc.h Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/unix/native/libjava/childproc.h Tue Mar 31 16:23:01 2015 -0700
@@ -101,7 +101,6 @@
const char **envv;
const char *pdir;
int redirectErrorStream;
- void *clone_stack;
} ChildStuff;
/* following used in addition when mode is SPAWN */
--- a/jdk/src/java.base/unix/native/libjava/jni_util_md.c Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/java.base/unix/native/libjava/jni_util_md.c Tue Mar 31 16:23:01 2015 -0700
@@ -55,10 +55,12 @@
size_t
getLastErrorString(char *buf, size_t len)
{
+ char *err;
+ size_t n;
if (errno == 0 || len < 1) return 0;
- const char *err = strerror(errno);
- size_t n = strlen(err);
+ err = strerror(errno);
+ n = strlen(err);
if (n >= len)
n = len - 1;
--- a/jdk/src/jdk.crypto.pkcs11/share/classes/sun/security/pkcs11/SessionManager.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/jdk.crypto.pkcs11/share/classes/sun/security/pkcs11/SessionManager.java Tue Mar 31 16:23:01 2015 -0700
@@ -90,6 +90,7 @@
// maximum number of active sessions during this invocation, for debugging
private int maxActiveSessions;
+ private Object maxActiveSessionsLock;
// flags to use in the C_OpenSession() call
private final long openSessionFlags;
@@ -113,6 +114,9 @@
this.token = token;
this.objSessions = new Pool(this);
this.opSessions = new Pool(this);
+ if (debug != null) {
+ maxActiveSessionsLock = new Object();
+ }
}
// returns whether only a fairly low number of sessions are
@@ -212,7 +216,7 @@
Session session = new Session(token, id);
activeSessions.incrementAndGet();
if (debug != null) {
- synchronized(this) {
+ synchronized(maxActiveSessionsLock) {
if (activeSessions.get() > maxActiveSessions) {
maxActiveSessions = activeSessions.get();
if (maxActiveSessions % 10 == 0) {
--- a/jdk/src/jdk.localedata/share/classes/sun/text/resources/de/FormatData_de.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/jdk.localedata/share/classes/sun/text/resources/de/FormatData_de.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2015, 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
@@ -142,7 +142,7 @@
new String[] {
"Jan", // abb january
"Feb", // abb february
- "Mrz", // abb march
+ "M\u00e4r", // abb march
"Apr", // abb april
"Mai", // abb may
"Jun", // abb june
--- a/jdk/src/jdk.zipfs/share/classes/jdk/nio/zipfs/ZipConstants.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/jdk.zipfs/share/classes/jdk/nio/zipfs/ZipConstants.java Tue Mar 31 16:23:01 2015 -0700
@@ -184,10 +184,19 @@
return (LG(b, n)) | (LG(b, n + 4) << 32);
}
- static final long GETSIG(byte[] b) {
- return LG(b, 0);
+ static long getSig(byte[] b, int n) { return LG(b, n); }
+
+ private static boolean pkSigAt(byte[] b, int n, int b1, int b2) {
+ return b[n] == 'P' & b[n + 1] == 'K' & b[n + 2] == b1 & b[n + 3] == b2;
}
+ static boolean cenSigAt(byte[] b, int n) { return pkSigAt(b, n, 1, 2); }
+ static boolean locSigAt(byte[] b, int n) { return pkSigAt(b, n, 3, 4); }
+ static boolean endSigAt(byte[] b, int n) { return pkSigAt(b, n, 5, 6); }
+ static boolean extSigAt(byte[] b, int n) { return pkSigAt(b, n, 7, 8); }
+ static boolean end64SigAt(byte[] b, int n) { return pkSigAt(b, n, 6, 6); }
+ static boolean locator64SigAt(byte[] b, int n) { return pkSigAt(b, n, 6, 7); }
+
// local file (LOC) header fields
static final long LOCSIG(byte[] b) { return LG(b, 0); } // signature
static final int LOCVER(byte[] b) { return SH(b, 4); } // version needed to extract
--- a/jdk/src/jdk.zipfs/share/classes/jdk/nio/zipfs/ZipFileSystem.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/src/jdk.zipfs/share/classes/jdk/nio/zipfs/ZipFileSystem.java Tue Mar 31 16:23:01 2015 -0700
@@ -1060,7 +1060,7 @@
int pos = 0;
int limit = cen.length - ENDHDR;
while (pos < limit) {
- if (CENSIG(cen, pos) != CENSIG)
+ if (!cenSigAt(cen, pos))
zerror("invalid CEN header (bad signature)");
int method = CENHOW(cen, pos);
int nlen = CENNAM(cen, pos);
@@ -1894,7 +1894,7 @@
throws IOException
{
byte[] cen = zipfs.cen;
- if (CENSIG(cen, pos) != CENSIG)
+ if (!cenSigAt(cen, pos))
zerror("invalid CEN header (bad signature)");
versionMade = CENVEM(cen, pos);
version = CENVER(cen, pos);
@@ -2057,9 +2057,9 @@
assert (buf.length >= LOCHDR);
if (zipfs.readFullyAt(buf, 0, LOCHDR , pos) != LOCHDR)
throw new ZipException("loc: reading failed");
- if (LOCSIG(buf) != LOCSIG)
+ if (!locSigAt(buf, 0))
throw new ZipException("loc: wrong sig ->"
- + Long.toString(LOCSIG(buf), 16));
+ + Long.toString(getSig(buf, 0), 16));
//startPos = pos;
version = LOCVER(buf);
flag = LOCFLG(buf);
@@ -2289,9 +2289,9 @@
if (zipfs.readFullyAt(buf, 0, buf.length , locoff)
!= buf.length)
throw new ZipException("loc: reading failed");
- if (LOCSIG(buf) != LOCSIG)
+ if (!locSigAt(buf, 0))
throw new ZipException("loc: wrong sig ->"
- + Long.toString(LOCSIG(buf), 16));
+ + Long.toString(getSig(buf, 0), 16));
int locElen = LOCEXT(buf);
if (locElen < 9) // EXTT is at lease 9 bytes
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/jdk/test/java/util/Calendar/Bug8075548.java Tue Mar 31 16:23:01 2015 -0700
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) 2015, 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 8075548
+ * @summary Make sure that the format form of month names are produced when there are
+ * no stand-alone ones available.
+ */
+
+import java.text.*;
+import java.util.*;
+import static java.util.Calendar.*;
+
+public class Bug8075548 {
+ static int errors = 0;
+
+ public static void main(String[] args) throws Throwable {
+ Date date = new SimpleDateFormat("yyyy-MM-dd", Locale.US).parse("2010-09-15");
+ String[][] FORMAT_PAIRS = {
+ { "LLLL", "MMMM" },
+ { "LLL", "MMM" }
+ };
+ Locale[] LOCALES = {
+ Locale.ENGLISH, Locale.FRENCH, Locale.GERMAN, Locale.JAPANESE
+ };
+
+ for (Locale locale : LOCALES) {
+ for (String[] formats : FORMAT_PAIRS) {
+ String el = new SimpleDateFormat(formats[0], locale).format(date);
+ String em = new SimpleDateFormat(formats[1], locale).format(date);
+ if (!el.equals(em)) {
+ errors++;
+ System.err.println(locale + ": " +
+ formats[0] + " -> " + el + ", " +
+ formats[1] + " -> " + em);
+ }
+ }
+ }
+
+ // Test Calendar.getDisplayName() and .getDisplayNames().
+ for (Locale locale : LOCALES) {
+ testDisplayNames(locale, LONG_FORMAT, LONG_STANDALONE);
+ testDisplayNames(locale, SHORT_FORMAT, SHORT_STANDALONE);
+ testDisplayNames(locale, NARROW_FORMAT, NARROW_STANDALONE);
+ }
+
+ if (errors > 0) {
+ throw new RuntimeException("Failed");
+ }
+ }
+
+ private static void testDisplayNames(Locale locale, int formatStyle, int standaloneStyle) {
+ Map<String, Integer> map = new HashMap<>();
+ for (int month = JANUARY; month <= DECEMBER; month++) {
+ Calendar cal = new GregorianCalendar(2015, month, 1);
+ String format = cal.getDisplayName(MONTH, formatStyle, locale);
+ String standalone = cal.getDisplayName(MONTH, standaloneStyle, locale);
+ if (!format.equals(standalone)) {
+ System.err.println("Calendar.getDisplayName: " + (month+1) +
+ ", locale=" + locale +
+ ", format=" + format + ", standalone=" + standalone);
+ errors++;
+ }
+ if (standalone != null) {
+ map.put(standalone, month);
+ }
+ }
+ if (formatStyle == NARROW_FORMAT) {
+ // Narrow styles don't support unique names.
+ // (e.g., "J" for JANUARY, JUNE, and JULY)
+ return;
+ }
+ Calendar cal = new GregorianCalendar(2015, JANUARY, 1);
+ Map<String, Integer> mapStandalone = cal.getDisplayNames(MONTH, standaloneStyle, locale);
+ if (!map.equals(mapStandalone)) {
+ System.err.printf("Calendar.getDisplayNames: locale=%s%n map=%s%n mapStandalone=%s%n",
+ locale, map, mapStandalone);
+ errors++;
+ }
+ Map<String, Integer> mapAll = cal.getDisplayNames(MONTH, ALL_STYLES, locale);
+ if (!mapAll.entrySet().containsAll(map.entrySet())) {
+ System.err.printf("Calendar.getDisplayNames: locale=%s%n map=%s%n mapAll=%s%n",
+ locale, map, mapAll);
+ errors++;
+ }
+ }
+}
--- a/jdk/test/java/util/Calendar/NarrowNamesTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/java/util/Calendar/NarrowNamesTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -86,7 +86,19 @@
"\u6728",
"\u91d1",
"\u571f");
- testMap(THTH, MONTH, NARROW_FORMAT); // expect null
+ testMap(THTH, MONTH, NARROW_FORMAT,
+ "\u0e21.\u0e04.",
+ "\u0e01.\u0e1e.",
+ "\u0e21\u0e35.\u0e04.",
+ "\u0e40\u0e21.\u0e22.",
+ "\u0e1e.\u0e04.",
+ "\u0e21\u0e34.\u0e22", // no last dot
+ "\u0e01.\u0e04.",
+ "\u0e2a.\u0e04.",
+ "\u0e01.\u0e22.",
+ "\u0e15.\u0e04.",
+ "\u0e1e.\u0e22.",
+ "\u0e18.\u0e04.");
testMap(THTH, MONTH, NARROW_STANDALONE,
"\u0e21.\u0e04.",
"\u0e01.\u0e1e.",
@@ -146,7 +158,7 @@
Calendar cal = Calendar.getInstance(locale);
Map<String, Integer> got = cal.getDisplayNames(field, style, locale);
if (!(expectedMap == null && got == null)
- && !expectedMap.equals(got)) {
+ && !(expectedMap != null && expectedMap.equals(got))) {
System.err.printf("testMap: locale=%s, field=%d, style=%d, expected=%s, got=%s%n",
locale, field, style, expectedMap, got);
errors++;
--- a/jdk/test/java/util/stream/boottest/java/util/stream/UnorderedTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/java/util/stream/boottest/java/util/stream/UnorderedTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2015, 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
@@ -251,7 +251,7 @@
final int lastLimitIndex = l;
return s -> {
- if (lastLimitIndex == -1)
+ if (lastLimitIndex == -1 && fs.size() > 0)
s = fi.apply(s);
for (int i = 0; i < fs.size(); i++) {
s = fs.get(i).apply(s);
--- a/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/stream/CountTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/stream/CountTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -24,11 +24,12 @@
/**
* @test
* @summary Tests counting of streams
- * @bug 8031187 8067969
+ * @bug 8031187 8067969 8075307
*/
package org.openjdk.tests.java.util.stream;
+import java.util.HashSet;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.stream.DoubleStream;
import java.util.stream.DoubleStreamTestDataProvider;
@@ -59,6 +60,19 @@
terminal(s -> s.filter(e -> true), Stream::count).
expectedResult(expectedCount).
exercise();
+
+ // Test with stateful distinct op that is a barrier or lazy
+ // depending if source is not already distinct and encounter order is
+ // preserved or not
+ expectedCount = data.into(new HashSet<>()).size();
+ withData(data).
+ terminal(Stream::distinct, Stream::count).
+ expectedResult(expectedCount).
+ exercise();
+ withData(data).
+ terminal(s -> s.unordered().distinct(), Stream::count).
+ expectedResult(expectedCount).
+ exercise();
}
@Test(dataProvider = "IntStreamTestData", dataProviderClass = IntStreamTestDataProvider.class)
@@ -74,6 +88,16 @@
terminal(s -> s.filter(e -> true), IntStream::count).
expectedResult(expectedCount).
exercise();
+
+ expectedCount = data.into(new HashSet<>()).size();
+ withData(data).
+ terminal(IntStream::distinct, IntStream::count).
+ expectedResult(expectedCount).
+ exercise();
+ withData(data).
+ terminal(s -> s.unordered().distinct(), IntStream::count).
+ expectedResult(expectedCount).
+ exercise();
}
@Test(dataProvider = "LongStreamTestData", dataProviderClass = LongStreamTestDataProvider.class)
@@ -89,6 +113,16 @@
terminal(s -> s.filter(e -> true), LongStream::count).
expectedResult(expectedCount).
exercise();
+
+ expectedCount = data.into(new HashSet<>()).size();
+ withData(data).
+ terminal(LongStream::distinct, LongStream::count).
+ expectedResult(expectedCount).
+ exercise();
+ withData(data).
+ terminal(s -> s.unordered().distinct(), LongStream::count).
+ expectedResult(expectedCount).
+ exercise();
}
@Test(dataProvider = "DoubleStreamTestData", dataProviderClass = DoubleStreamTestDataProvider.class)
@@ -104,6 +138,16 @@
terminal(s -> s.filter(e -> true), DoubleStream::count).
expectedResult(expectedCount).
exercise();
+
+ expectedCount = data.into(new HashSet<>()).size();
+ withData(data).
+ terminal(DoubleStream::distinct, DoubleStream::count).
+ expectedResult(expectedCount).
+ exercise();
+ withData(data).
+ terminal(s -> s.unordered().distinct(), DoubleStream::count).
+ expectedResult(expectedCount).
+ exercise();
}
public void testNoEvaluationForSizedStream() {
@@ -111,24 +155,36 @@
AtomicInteger ai = new AtomicInteger();
Stream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).count();
assertEquals(ai.get(), 0);
+
+ Stream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).parallel().count();
+ assertEquals(ai.get(), 0);
}
{
AtomicInteger ai = new AtomicInteger();
IntStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).count();
assertEquals(ai.get(), 0);
+
+ IntStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).parallel().count();
+ assertEquals(ai.get(), 0);
}
{
AtomicInteger ai = new AtomicInteger();
LongStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).count();
assertEquals(ai.get(), 0);
+
+ LongStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).parallel().count();
+ assertEquals(ai.get(), 0);
}
{
AtomicInteger ai = new AtomicInteger();
DoubleStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).count();
assertEquals(ai.get(), 0);
+
+ DoubleStream.of(1, 2, 3, 4).peek(e -> ai.getAndIncrement()).parallel().count();
+ assertEquals(ai.get(), 0);
}
}
}
--- a/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/stream/DistinctOpTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/stream/DistinctOpTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2015, 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
@@ -128,7 +128,7 @@
@Test(dataProvider = "StreamTestData<Integer>", dataProviderClass = StreamTestDataProvider.class)
public void testDistinctDistinct(String name, TestData.OfRef<Integer> data) {
Collection<Integer> result = withData(data)
- .stream(s -> s.distinct().distinct(), new CollectorOps.TestParallelSizedOp<>())
+ .stream(s -> s.distinct().distinct())
.exercise();
assertUnique(result);
}
--- a/jdk/test/java/util/zip/EntryCount64k.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/java/util/zip/EntryCount64k.java Tue Mar 31 16:23:01 2015 -0700
@@ -24,33 +24,76 @@
/**
* @test
* @summary Test java.util.zip behavior with ~64k entries
+ * @library /lib/testlibrary
* @run main/othervm EntryCount64k
* @run main/othervm -Djdk.util.zip.inhibitZip64=true EntryCount64k
* @run main/othervm -Djdk.util.zip.inhibitZip64=false EntryCount64k
*/
-import java.io.*;
-import java.util.*;
-import java.util.zip.*;
+import java.io.BufferedInputStream;
+import java.io.BufferedOutputStream;
+import java.io.File;
+import java.nio.file.Files;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.RandomAccessFile;
+import java.nio.file.Paths;
+import java.util.Enumeration;
+import java.util.zip.ZipEntry;
+import java.util.zip.ZipFile;
+import java.util.zip.ZipInputStream;
+import java.util.zip.ZipOutputStream;
+
+import jdk.testlibrary.OutputAnalyzer;
+import jdk.testlibrary.ProcessTools;
public class EntryCount64k {
+ public static class Main {
+ public static void main(String[] args) {
+ System.out.print("Main");
+ }
+ }
- public static void main(String[] args) throws Exception {
- for (int i = (1 << 16) - 2; i < (1 << 16) + 2; i++)
+ static final String MAIN_CLASS = "EntryCount64k$Main";
+ static final String THIS_CLASS = "EntryCount64k";
+ static final String[] SPECIAL_CLASSES = { MAIN_CLASS, THIS_CLASS };
+ // static final String[] SPECIAL_CLASSES = { MAIN_CLASS };
+ static final int SPECIAL_COUNT = 1 + SPECIAL_CLASSES.length;
+
+ public static void main(String[] args) throws Throwable {
+ for (int i = (1 << 16) - 3; i < (1 << 16) + 2; i++)
test(i);
}
- static void test(int entryCount) throws Exception {
+ static void test(int entryCount) throws Throwable {
File zipFile = new File("EntryCount64k-tmp.zip");
zipFile.delete();
- try (ZipOutputStream zos =
- new ZipOutputStream(
- new BufferedOutputStream(
- new FileOutputStream(zipFile)))) {
- for (int i = 0; i < entryCount; i++) {
- ZipEntry e = new ZipEntry(Integer.toString(i));
- zos.putNextEntry(e);
+ try (FileOutputStream fos = new FileOutputStream(zipFile);
+ BufferedOutputStream bos = new BufferedOutputStream(fos);
+ ZipOutputStream zos = new ZipOutputStream(bos)) {
+
+ // Add entries to allow the zip file to be used with "java -jar"
+ zos.putNextEntry(new ZipEntry("META-INF/MANIFEST.MF"));
+ for (String line : new String[] {
+ "Manifest-Version: 1.0",
+ "Main-Class: " + MAIN_CLASS,
+ })
+ zos.write((line + "\n").getBytes("US-ASCII"));
+ zos.closeEntry();
+
+ String testClasses = System.getProperty("test.classes");
+ for (String className : SPECIAL_CLASSES) {
+ String baseName = className + ".class";
+ ZipEntry ze = new ZipEntry(baseName);
+ File file = new File(testClasses, baseName);
+ zos.putNextEntry(ze);
+ Files.copy(file.toPath(), zos);
+ zos.closeEntry();
+ }
+
+ for (int i = SPECIAL_COUNT; i < entryCount; i++) {
+ zos.putNextEntry(new ZipEntry(Integer.toString(i)));
zos.closeEntry();
}
}
@@ -86,16 +129,16 @@
return false;
}
- static void checkCanRead(File zipFile, int entryCount) throws Exception {
+ static void checkCanRead(File zipFile, int entryCount) throws Throwable {
// Check ZipInputStream API
- try (ZipInputStream zis =
- new ZipInputStream(
- new BufferedInputStream(
- new FileInputStream(zipFile)))) {
+ try (FileInputStream fis = new FileInputStream(zipFile);
+ BufferedInputStream bis = new BufferedInputStream(fis);
+ ZipInputStream zis = new ZipInputStream(bis)) {
for (int i = 0; i < entryCount; i++) {
ZipEntry e = zis.getNextEntry();
- if (Integer.parseInt(e.getName()) != i)
- throw new AssertionError();
+ if (i >= SPECIAL_COUNT) // skip special entries
+ if (Integer.parseInt(e.getName()) != i)
+ throw new AssertionError(e.getName());
}
if (zis.getNextEntry() != null)
throw new AssertionError();
@@ -106,8 +149,9 @@
Enumeration<? extends ZipEntry> en = zf.entries();
for (int i = 0; i < entryCount; i++) {
ZipEntry e = en.nextElement();
- if (Integer.parseInt(e.getName()) != i)
- throw new AssertionError();
+ if (i >= SPECIAL_COUNT) // skip special entries
+ if (Integer.parseInt(e.getName()) != i)
+ throw new AssertionError();
}
if (en.hasMoreElements()
|| (zf.size() != entryCount)
@@ -115,5 +159,15 @@
|| (zf.getEntry(Integer.toString(entryCount)) != null))
throw new AssertionError();
}
+
+ // Check java -jar
+ String javaHome = System.getProperty("java.home");
+ String java = Paths.get(javaHome, "bin", "java").toString();
+ String[] cmd = { java, "-jar", zipFile.getName() };
+ ProcessBuilder pb = new ProcessBuilder(cmd);
+ OutputAnalyzer a = ProcessTools.executeProcess(pb);
+ a.shouldHaveExitValue(0);
+ a.stdoutShouldMatch("\\AMain\\Z");
+ a.stderrShouldMatch("\\A\\Z");
}
}
--- a/jdk/test/javax/net/ssl/FixingJavadocs/ComURLNulls.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/javax/net/ssl/FixingJavadocs/ComURLNulls.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2015, 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
@@ -80,7 +80,7 @@
}
try {
- urlc.getServerCertificateChain();
+ urlc.getServerCertificates();
} catch (IllegalStateException e) {
System.out.print("Caught proper exception: ");
System.out.println(e.getMessage());
--- a/jdk/test/javax/xml/jaxp/transform/8062923/XslSubstringTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/javax/xml/jaxp/transform/8062923/XslSubstringTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -23,10 +23,11 @@
/**
* @test
- * @bug 8062923 8062924
+ * @bug 8062923 8062924 8074297
* @run testng XslSubstringTest
* @summary Test xsl substring function with negative, Inf and
- * NaN length and few other use cases
+ * NaN length and few other use cases. Also test proper
+ * processing of supplementary characters by substring function.
*/
import java.io.StringReader;
@@ -39,6 +40,7 @@
import javax.xml.transform.stream.StreamSource;
import static org.testng.Assert.assertEquals;
+import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
public class XslSubstringTest {
@@ -50,6 +52,31 @@
+ "<xsl:template match='/'><t>";
final String xslPost = "</t></xsl:template></xsl:stylesheet>";
+ @DataProvider(name = "GeneralTestsData")
+ private Object[][] xmls() {
+ return new Object[][] {
+ { "|<xsl:value-of select=\"substring('asdf',2, 1)\"/>|", "<t>|s|</t>"},
+ { "|<xsl:value-of select=\"substring('asdf',2, 1 div 0)\"/>|", "<t>|sdf|</t>"},
+ { "|<xsl:value-of select=\"substring('asdf',2, -0 div 0)\"/>|", "<t>||</t>" },
+ { "|<xsl:value-of select=\"substring('asdf',2, 1 div 0)\"/>|", "<t>|sdf|</t>" },
+ };
+ }
+
+ @DataProvider(name = "SupplementaryCharactersTestData")
+ private Object[][] bug8074297() {
+ return new Object[][] {
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 3)\"/>|", "<t>|BC|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 3, 1)\"/>|", "<t>|B|</t>" },
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 2, 2)\"/>|", "<t>|AB|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 3, 2)\"/>|", "<t>|BC|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 3, 4)\"/>|", "<t>|BC|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 1, 1)\"/>|", "<t>|𠀋|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 2, 1)\"/>|", "<t>|A|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', 1, 1 div 0)\"/>|", "<t>|𠀋ABC|</t>"},
+ { "|<xsl:value-of select=\"substring('𠀋ABC', -10, 1 div 0)\"/>|", "<t>|𠀋ABC|</t>"},
+ };
+ }
+
private String testTransform(String xsl) throws Exception {
//Prepare sources for transormation
Source src = new StreamSource(new StringReader(xml));
@@ -78,27 +105,14 @@
"<t>||</t>");
}
- @Test
- public void testGeneral1() throws Exception {
- assertEquals(testTransform("|<xsl:value-of select=\"substring('asdf',2, 1)\"/>|"),
- "<t>|s|</t>");
- }
-
- @Test
- public void testGeneral2() throws Exception {
- assertEquals(testTransform("|<xsl:value-of select=\"substring('asdf',2, 1 div 0)\"/>|"),
- "<t>|sdf|</t>");
+ @Test(dataProvider = "GeneralTestsData")
+ public void testGeneralAll(String xsl, String result) throws Exception {
+ assertEquals(testTransform(xsl), result);
}
- @Test
- public void testGeneral3() throws Exception {
- assertEquals(testTransform("|<xsl:value-of select=\"substring('asdf',2, -0 div 0)\"/>|"),
- "<t>||</t>");
+ @Test(dataProvider = "SupplementaryCharactersTestData")
+ public void testSupplementCharacters(String xsl, String result) throws Exception {
+ assertEquals(testTransform(xsl), result);
}
- @Test
- public void testGeneral4() throws Exception {
- assertEquals(testTransform("|<xsl:value-of select=\"substring('asdf',2, 0 div 0)\"/>|"),
- "<t>||</t>");
- }
}
--- a/jdk/test/sun/net/www/protocol/https/NewImpl/ComHTTPSConnection.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/net/www/protocol/https/NewImpl/ComHTTPSConnection.java Tue Mar 31 16:23:01 2015 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2015, 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
@@ -34,8 +34,8 @@
import java.io.*;
import java.net.*;
+import java.security.cert.Certificate;
import javax.net.ssl.*;
-import javax.security.cert.*;
import com.sun.net.ssl.HostnameVerifier;
import com.sun.net.ssl.HttpsURLConnection;
@@ -240,8 +240,8 @@
System.out.println("Cipher Suite: " +
((HttpsURLConnection)urlc).getCipherSuite());
- X509Certificate[] certs =
- ((HttpsURLConnection)urlc).getServerCertificateChain();
+ Certificate[] certs =
+ ((HttpsURLConnection)urlc).getServerCertificates();
for (int i = 0; i < certs.length; i++) {
System.out.println(certs[0]);
}
--- a/jdk/test/sun/text/resources/LocaleData Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/text/resources/LocaleData Tue Mar 31 16:23:01 2015 -0700
@@ -8279,3 +8279,6 @@
FormatData/fi/DatePatterns/1=d. MMMM yyyy
FormatData/fi/DatePatterns/2=d.M.yyyy
FormatData/fi/DatePatterns/3=d.M.yyyy
+
+# bug #8075173
+FormatData/de/standalone.MonthAbbreviations/2=M\u00e4r
--- a/jdk/test/sun/text/resources/LocaleDataTest.java Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/text/resources/LocaleDataTest.java Tue Mar 31 16:23:01 2015 -0700
@@ -36,7 +36,7 @@
* 6919624 6998391 7019267 7020960 7025837 7020583 7036905 7066203 7101495
* 7003124 7085757 7028073 7171028 7189611 8000983 7195759 8004489 8006509
* 7114053 7074882 7040556 8013836 8021121 6192407 6931564 8027695 8017142
- * 8037343 8055222 8042126 8074791
+ * 8037343 8055222 8042126 8074791 8075173
* @summary Verify locale data
*
*/
--- a/jdk/test/sun/util/calendar/zi/tzdata/VERSION Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/VERSION Tue Mar 31 16:23:01 2015 -0700
@@ -21,4 +21,4 @@
# or visit www.oracle.com if you need additional information or have any
# questions.
#
-tzdata2015a
+tzdata2015b
--- a/jdk/test/sun/util/calendar/zi/tzdata/asia Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/asia Tue Mar 31 16:23:01 2015 -0700
@@ -1927,6 +1927,13 @@
# was at the start of 2008-03-31 (the day of Steffen Thorsen's report);
# this is almost surely wrong.
+# From Ganbold Tsagaankhuu (2015-03-10):
+# It seems like yesterday Mongolian Government meeting has concluded to use
+# daylight saving time in Mongolia.... Starting at 2:00AM of last Saturday of
+# March 2015, daylight saving time starts. And 00:00AM of last Saturday of
+# September daylight saving time ends. Source:
+# http://zasag.mn/news/view/8969
+
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Mongol 1983 1984 - Apr 1 0:00 1:00 S
Rule Mongol 1983 only - Oct 1 0:00 0 -
@@ -1947,6 +1954,8 @@
Rule Mongol 2001 only - Apr lastSat 2:00 1:00 S
Rule Mongol 2001 2006 - Sep lastSat 2:00 0 -
Rule Mongol 2002 2006 - Mar lastSat 2:00 1:00 S
+Rule Mongol 2015 max - Mar lastSat 2:00 1:00 S
+Rule Mongol 2015 max - Sep lastSat 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
# Hovd, a.k.a. Chovd, Dund-Us, Dzhargalant, Khovd, Jirgalanta
@@ -2365,13 +2374,19 @@
# official source...:
# http://www.palestinecabinet.gov.ps/ar/Views/ViewDetails.aspx?pid=1252
-# From Paul Eggert (2013-09-24):
-# For future dates, guess the last Thursday in March at 24:00 through
-# the first Friday on or after September 21 at 00:00. This is consistent with
-# the predictions in today's editions of the following URLs,
-# which are for Gaza and Hebron respectively:
-# http://www.timeanddate.com/worldclock/timezone.html?n=702
-# http://www.timeanddate.com/worldclock/timezone.html?n=2364
+# From Steffen Thorsen (2015-03-03):
+# Sources such as http://www.alquds.com/news/article/view/id/548257
+# and http://www.raya.ps/ar/news/890705.html say Palestine areas will
+# start DST on 2015-03-28 00:00 which is one day later than expected.
+#
+# From Paul Eggert (2015-03-03):
+# http://www.timeanddate.com/time/change/west-bank/ramallah?year=2014
+# says that the fall 2014 transition was Oct 23 at 24:00.
+# For future dates, guess the last Friday in March at 24:00 through
+# the first Friday on or after October 21 at 00:00. This is consistent with
+# the predictions in today's editions of the following URLs:
+# http://www.timeanddate.com/time/change/gaza-strip/gaza
+# http://www.timeanddate.com/time/change/west-bank/hebron
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule EgyptAsia 1957 only - May 10 0:00 1:00 S
@@ -2397,9 +2412,11 @@
Rule Palestine 2011 only - Aug 1 0:00 0 -
Rule Palestine 2011 only - Aug 30 0:00 1:00 S
Rule Palestine 2011 only - Sep 30 0:00 0 -
-Rule Palestine 2012 max - Mar lastThu 24:00 1:00 S
+Rule Palestine 2012 2014 - Mar lastThu 24:00 1:00 S
Rule Palestine 2012 only - Sep 21 1:00 0 -
-Rule Palestine 2013 max - Sep Fri>=21 0:00 0 -
+Rule Palestine 2013 only - Sep Fri>=21 0:00 0 -
+Rule Palestine 2014 max - Oct Fri>=21 0:00 0 -
+Rule Palestine 2015 max - Mar lastFri 24:00 1:00 S
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Gaza 2:17:52 - LMT 1900 Oct
--- a/jdk/test/sun/util/calendar/zi/tzdata/australasia Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/australasia Tue Mar 31 16:23:01 2015 -0700
@@ -396,6 +396,7 @@
9:39:00 - LMT 1901 # Agana
10:00 - GST 2000 Dec 23 # Guam
10:00 - ChST # Chamorro Standard Time
+Link Pacific/Guam Pacific/Saipan # N Mariana Is
# Kiribati
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -411,12 +412,7 @@
14:00 - LINT
# N Mariana Is
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone Pacific/Saipan -14:17:00 - LMT 1844 Dec 31
- 9:43:00 - LMT 1901
- 9:00 - MPT 1969 Oct # N Mariana Is Time
- 10:00 - MPT 2000 Dec 23
- 10:00 - ChST # Chamorro Standard Time
+# See Pacific/Guam.
# Marshall Is
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
@@ -586,6 +582,7 @@
-11:00 - NST 1967 Apr # N=Nome
-11:00 - BST 1983 Nov 30 # B=Bering
-11:00 - SST # S=Samoa
+Link Pacific/Pago_Pago Pacific/Midway # in US minor outlying islands
# Samoa (formerly and also known as Western Samoa)
@@ -767,23 +764,7 @@
# uninhabited
# Midway
-#
-# From Mark Brader (2005-01-23):
-# [Fallacies and Fantasies of Air Transport History, by R.E.G. Davies,
-# published 1994 by Paladwr Press, McLean, VA, USA; ISBN 0-9626483-5-3]
-# reproduced a Pan American Airways timetable from 1936, for their weekly
-# "Orient Express" flights between San Francisco and Manila, and connecting
-# flights to Chicago and the US East Coast. As it uses some time zone
-# designations that I've never seen before:....
-# Fri. 6:30A Lv. HONOLOLU (Pearl Harbor), H.I. H.L.T. Ar. 5:30P Sun.
-# " 3:00P Ar. MIDWAY ISLAND . . . . . . . . . M.L.T. Lv. 6:00A "
-#
-Zone Pacific/Midway -11:49:28 - LMT 1901
- -11:00 - NST 1956 Jun 3
- -11:00 1:00 NDT 1956 Sep 2
- -11:00 - NST 1967 Apr # N=Nome
- -11:00 - BST 1983 Nov 30 # B=Bering
- -11:00 - SST # S=Samoa
+# See Pacific/Pago_Pago.
# Palmyra
# uninhabited since World War II; was probably like Pacific/Kiritimati
--- a/jdk/test/sun/util/calendar/zi/tzdata/europe Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/europe Tue Mar 31 16:23:01 2015 -0700
@@ -2423,7 +2423,7 @@
4:00 Russia VOL%sT 1989 Mar 26 2:00s # Volgograd T
3:00 Russia VOL%sT 1991 Mar 31 2:00s
4:00 - VOLT 1992 Mar 29 2:00s
- 3:00 Russia MSK 2011 Mar 27 2:00s
+ 3:00 Russia MSK/MSD 2011 Mar 27 2:00s
4:00 - MSK 2014 Oct 26 2:00s
3:00 - MSK
--- a/jdk/test/sun/util/calendar/zi/tzdata/northamerica Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/northamerica Tue Mar 31 16:23:01 2015 -0700
@@ -2335,8 +2335,24 @@
# "...the new time zone will come into effect at two o'clock on the first Sunday
# of February, when we will have to advance the clock one hour from its current
# time..."
+# Also, the new zone will not use DST.
#
-# Also, the new zone will not use DST.
+# From Carlos Raúl Perasso (2015-02-02):
+# The decree that modifies the Mexican Hour System Law has finally
+# been published at the Diario Oficial de la Federación
+# http://www.dof.gob.mx/nota_detalle.php?codigo=5380123&fecha=31/01/2015
+# It establishes 5 zones for Mexico:
+# 1- Zona Centro (Central Zone): Corresponds to longitude 90 W,
+# includes most of Mexico, excluding what's mentioned below.
+# 2- Zona Pacífico (Pacific Zone): Longitude 105 W, includes the
+# states of Baja California Sur; Chihuahua; Nayarit (excluding Bahía
+# de Banderas which lies in Central Zone); Sinaloa and Sonora.
+# 3- Zona Noroeste (Northwest Zone): Longitude 120 W, includes the
+# state of Baja California.
+# 4- Zona Sureste (Southeast Zone): Longitude 75 W, includes the state
+# of Quintana Roo.
+# 5- The islands, reefs and keys shall take their timezone from the
+# longitude they are located at.
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
Rule Mexico 1939 only - Feb 5 0:00 1:00 D
@@ -2531,14 +2547,9 @@
###############################################################################
# Anguilla
+# Antigua and Barbuda
# See America/Port_of_Spain.
-# Antigua and Barbuda
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone America/Antigua -4:07:12 - LMT 1912 Mar 2
- -5:00 - EST 1951
- -4:00 - AST
-
# Bahamas
#
# For 1899 Milne gives -5:09:29.5; round that.
@@ -2604,10 +2615,7 @@
-4:00 US A%sT
# Cayman Is
-# Zone NAME GMTOFF RULES FORMAT [UNTIL]
-Zone America/Cayman -5:25:32 - LMT 1890 # Georgetown
- -5:07:11 - KMT 1912 Feb # Kingston Mean Time
- -5:00 - EST
+# See America/Panama.
# Costa Rica
@@ -3130,6 +3138,7 @@
Zone America/Panama -5:18:08 - LMT 1890
-5:19:36 - CMT 1908 Apr 22 # Colón Mean Time
-5:00 - EST
+Link America/Panama America/Cayman
# Puerto Rico
# There are too many San Juans elsewhere, so we'll use 'Puerto_Rico'.
--- a/jdk/test/sun/util/calendar/zi/tzdata/southamerica Tue Mar 31 08:48:53 2015 -0700
+++ b/jdk/test/sun/util/calendar/zi/tzdata/southamerica Tue Mar 31 16:23:01 2015 -0700
@@ -1229,10 +1229,13 @@
# DST Start: first Saturday of September 2014 (Sun 07 Sep 2014 04:00 UTC)
# http://www.diariooficial.interior.gob.cl//media/2014/02/19/do-20140219.pdf
-# From Juan Correa (2015-01-28):
-# ... today the Ministry of Energy announced that Chile will drop DST, will keep
-# "summer time" (UTC -3 / UTC -5) all year round....
-# http://www.minenergia.cl/ministerio/noticias/generales/ministerio-de-energia-anuncia.html
+# From Eduardo Romero Urra (2015-03-03):
+# Today has been published officially that Chile will use the DST time
+# permanently until March 25 of 2017
+# http://www.diariooficial.interior.gob.cl/media/2015/03/03/1-large.jpg
+#
+# From Paul Eggert (2015-03-03):
+# For now, assume that the extension will persist indefinitely.
# NOTE: ChileAQ rules for Antarctic bases are stored separately in the
# 'antarctica' file.
@@ -1291,7 +1294,7 @@
-3:00 - CLT
Zone Pacific/Easter -7:17:44 - LMT 1890
-7:17:28 - EMT 1932 Sep # Easter Mean Time
- -7:00 Chile EAS%sT 1982 Mar 13 3:00u # Easter Time
+ -7:00 Chile EAS%sT 1982 Mar 14 3:00u # Easter Time
-6:00 Chile EAS%sT 2015 Apr 26 3:00u
-5:00 - EAST
#
@@ -1626,6 +1629,7 @@
# These all agree with Trinidad and Tobago since 1970.
Link America/Port_of_Spain America/Anguilla
+Link America/Port_of_Spain America/Antigua
Link America/Port_of_Spain America/Dominica
Link America/Port_of_Spain America/Grenada
Link America/Port_of_Spain America/Guadeloupe