-
Notifications
You must be signed in to change notification settings - Fork 502
[Misc] Update version #735
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Ann-1024
wants to merge
1
commit into
standard
Choose a base branch
from
dragonwell_standard-8.27.26
base: standard
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+3
−3
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Summary: Update dragonwell version Testing: CICD Reviewers: kuaiwei, yuleil Issue: #301
Ann-1024
commented
Nov 28, 2025
| @@ -1 +1 @@ | |||
| 8.462.8.26.25.01-GA No newline at end of file | |||
| 8.472.8.27.26.01-GA No newline at end of file | |||
Collaborator
Author
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
diff --git a/.github/workflows/freetype.vcxproj b/.github/workflows/freetype.vcxproj
index 1ebfb7fe0a..d7c0f302fe 100644
--- a/.github/workflows/freetype.vcxproj
+++ b/.github/workflows/freetype.vcxproj
@@ -78,7 +78,7 @@
-->
<PropertyGroup Label="Globals">
<ProjectGuid>{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}</ProjectGuid>
- <WindowsTargetPlatformVersion>10.0.19041.0</WindowsTargetPlatformVersion>
+ <WindowsTargetPlatformVersion>10.0.17763.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
diff --git a/.github/workflows/submit.yml b/.github/workflows/submit.yml
index ee31fda329..c62e269426 100644
--- a/.github/workflows/submit.yml
+++ b/.github/workflows/submit.yml
@@ -405,7 +405,7 @@ jobs:
--verbose
--include=fakeroot,symlinks,build-essential,libx11-dev,libxext-dev,libxrender-dev,libxrandr-dev,libxtst-dev,libxt-dev,libcups2-dev,libfontconfig1-dev,libasound2-dev,libfreetype6-dev,libpng-dev,libffi-dev
--resolve-deps
- bookworm
+ bullseye
~/sysroot-${{ matrix.debian-arch }}
http://httpredir.debian.org/debian/
if: matrix.debian-arch != '' && steps.cache-sysroot.outputs.cache-hit != 'true'
@@ -676,7 +676,7 @@ jobs:
windows_x64_build:
name: Windows x64
- runs-on: "windows-2025"
+ runs-on: "windows-2019"
needs: prerequisites
if: needs.prerequisites.outputs.should_run != 'false' && needs.prerequisites.outputs.platform_windows_x64 != 'false'
@@ -798,7 +798,7 @@ jobs:
'install --productId Microsoft.VisualStudio.Product.Community --channelId VisualStudio.15.Release
--add Microsoft.VisualStudio.Workload.NativeDesktop
--add Microsoft.VisualStudio.Component.VC.Tools.x86.x64
- --add Microsoft.VisualStudio.Component.Windows10SDK.19041
+ --add Microsoft.VisualStudio.Component.Windows10SDK.17763
--quiet --wait'
- name: Fix OpenJDK permissions
@@ -854,7 +854,7 @@ jobs:
windows_x86_build:
name: Windows x86
- runs-on: "windows-2025"
+ runs-on: "windows-2019"
needs: prerequisites
if: needs.prerequisites.outputs.should_run != 'false' && needs.prerequisites.outputs.platform_windows_x86 != 'false'
@@ -1028,7 +1028,7 @@ jobs:
windows_x64_test:
name: Windows x64
- runs-on: "windows-2025"
+ runs-on: "windows-2019"
needs:
- prerequisites
- windows_x64_build
@@ -1189,7 +1189,7 @@ jobs:
windows_x86_test:
name: Windows x86
- runs-on: "windows-2025"
+ runs-on: "windows-2019"
needs:
- prerequisites
- windows_x86_build
diff --git a/.jcheck/conf b/.jcheck/conf
index 125b39dfc7..93774730e7 100644
--- a/.jcheck/conf
+++ b/.jcheck/conf
@@ -1,7 +1,7 @@
[general]
project=jdk8u
jbs=JDK
-version=openjdk8u472
+version=openjdk8u462
[checks]
error=author,committer,reviewers,merge,issues,executable,symlink,message,hg-tag,whitespace
diff --git a/THIRD_PARTY_README b/THIRD_PARTY_README
index 2b29659272..f9aea78d64 100644
--- a/THIRD_PARTY_README
+++ b/THIRD_PARTY_README
@@ -3083,7 +3083,7 @@ included with JRE 8, JDK 8, and OpenJDK 8.
Apache Jakarta BCEL 5.1
Apache Santuario XML Security for Java 2.1.3
Apache Xalan-Java 2.7.2
- Apache Xerces Java 2.7.1
+ Apache Xerces Java 2.10.0
Apache XML Resolver 1.1
diff --git a/common/autoconf/version-numbers b/common/autoconf/version-numbers
index c47387c23f..73a0ffbd69 100644
--- a/common/autoconf/version-numbers
+++ b/common/autoconf/version-numbers
@@ -26,7 +26,7 @@
JDK_MAJOR_VERSION=1
JDK_MINOR_VERSION=8
JDK_MICRO_VERSION=0
-JDK_UPDATE_VERSION=472
+JDK_UPDATE_VERSION=462
LAUNCHER_NAME=openjdk
PRODUCT_NAME=OpenJDK
PRODUCT_SUFFIX="Runtime Environment"
diff --git a/dragonwell_version b/dragonwell_version
index ac7a0069e7..928e8d1b6b 100644
--- a/dragonwell_version
+++ b/dragonwell_version
@@ -19,5 +19,5 @@
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
#
-DRAGONWELL_VERSION=8.26.25
-DRAGONWELL_JDK_UPDATE_VERSION=462
+DRAGONWELL_VERSION=8.27.26
+DRAGONWELL_JDK_UPDATE_VERSION=472
diff --git a/hotspot/src/cpu/ppc/vm/c2_globals_ppc.hpp b/hotspot/src/cpu/ppc/vm/c2_globals_ppc.hpp
index 50f5592576..58e4f3887c 100644
--- a/hotspot/src/cpu/ppc/vm/c2_globals_ppc.hpp
+++ b/hotspot/src/cpu/ppc/vm/c2_globals_ppc.hpp
@@ -83,7 +83,7 @@ define_pd_global(intx, ReservedCodeCacheSize, 256*M);
define_pd_global(intx, CodeCacheExpansionSize, 64*K);
// Ergonomics related flags
-define_pd_global(uint64_t,MaxRAM, 128ULL*G);
+define_pd_global(uint64_t,MaxRAM, 4ULL*G);
define_pd_global(uintx, CodeCacheMinBlockLength, 4);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);
diff --git a/hotspot/src/os/windows/vm/os_windows.cpp b/hotspot/src/os/windows/vm/os_windows.cpp
index 0ac1a76d1e..3c6145cfbc 100644
--- a/hotspot/src/os/windows/vm/os_windows.cpp
+++ b/hotspot/src/os/windows/vm/os_windows.cpp
@@ -1833,10 +1833,7 @@ void os::win32::print_windows_version(outputStream* st) {
// - 2016 GA 10/2016 build: 14393
// - 2019 GA 11/2018 build: 17763
// - 2022 GA 08/2021 build: 20348
- // - 2025 Preview build : 26040
- if (build_number > 26039) {
- st->print("Server 2025");
- } else if (build_number > 20347) {
+ if (build_number > 20347) {
st->print("Server 2022");
} else if (build_number > 17762) {
st->print("Server 2019");
diff --git a/hotspot/src/share/vm/classfile/stackMapTable.cpp b/hotspot/src/share/vm/classfile/stackMapTable.cpp
index 13606ae161..547dcf64b9 100644
--- a/hotspot/src/share/vm/classfile/stackMapTable.cpp
+++ b/hotspot/src/share/vm/classfile/stackMapTable.cpp
@@ -122,16 +122,8 @@ bool StackMapTable::match_stackmap(
}
void StackMapTable::check_jump_target(
- StackMapFrame* frame, int bci, int offset, TRAPS) const {
+ StackMapFrame* frame, int32_t target, TRAPS) const {
ErrorContext ctx;
- // Jump targets must be within the method and the method size is limited. See JVMS 4.11
- int min_offset = -1 * max_method_code_size;
- if (offset < min_offset || offset > max_method_code_size) {
- frame->verifier()->verify_error(ErrorContext::bad_stackmap(bci, frame),
- "Illegal target of jump or branch (bci %d + offset %d)", bci, offset);
- return;
- }
- int target = bci + offset;
bool match = match_stackmap(
frame, target, true, false, &ctx, CHECK_VERIFY(frame->verifier()));
if (!match || (target < 0 || target >= _code_length)) {
diff --git a/hotspot/src/share/vm/classfile/stackMapTable.hpp b/hotspot/src/share/vm/classfile/stackMapTable.hpp
index 36fddb3988..a36a7ba3cf 100644
--- a/hotspot/src/share/vm/classfile/stackMapTable.hpp
+++ b/hotspot/src/share/vm/classfile/stackMapTable.hpp
@@ -86,7 +86,7 @@ class StackMapTable : public StackObj {
// Check jump instructions. Make sure there are no uninitialized
// instances on backward branch.
- void check_jump_target(StackMapFrame* frame, int bci, int offset, TRAPS) const;
+ void check_jump_target(StackMapFrame* frame, int32_t target, TRAPS) const;
// The following methods are only used inside this class.
diff --git a/hotspot/src/share/vm/classfile/verifier.cpp b/hotspot/src/share/vm/classfile/verifier.cpp
index 4662bf02a5..2dddd1fded 100644
--- a/hotspot/src/share/vm/classfile/verifier.cpp
+++ b/hotspot/src/share/vm/classfile/verifier.cpp
@@ -668,6 +668,7 @@ void ClassVerifier::verify_method(methodHandle m, TRAPS) {
// Merge with the next instruction
{
u2 index;
+ int target;
VerificationType type, type2;
VerificationType atype;
@@ -1479,8 +1480,9 @@ void ClassVerifier::verify_method(methodHandle m, TRAPS) {
case Bytecodes::_ifle:
current_frame.pop_stack(
VerificationType::integer_type(), CHECK_VERIFY(this));
+ target = bcs.dest();
stackmap_table.check_jump_target(
- ¤t_frame, bcs.bci(), bcs.get_offset_s2(), CHECK_VERIFY(this));
+ ¤t_frame, target, CHECK_VERIFY(this));
no_control_flow = false; break;
case Bytecodes::_if_acmpeq :
case Bytecodes::_if_acmpne :
@@ -1491,16 +1493,19 @@ void ClassVerifier::verify_method(methodHandle m, TRAPS) {
case Bytecodes::_ifnonnull :
current_frame.pop_stack(
VerificationType::reference_check(), CHECK_VERIFY(this));
+ target = bcs.dest();
stackmap_table.check_jump_target
- (¤t_frame, bcs.bci(), bcs.get_offset_s2(), CHECK_VERIFY(this));
+ (¤t_frame, target, CHECK_VERIFY(this));
no_control_flow = false; break;
case Bytecodes::_goto :
+ target = bcs.dest();
stackmap_table.check_jump_target(
- ¤t_frame, bcs.bci(), bcs.get_offset_s2(), CHECK_VERIFY(this));
+ ¤t_frame, target, CHECK_VERIFY(this));
no_control_flow = true; break;
case Bytecodes::_goto_w :
+ target = bcs.dest_w();
stackmap_table.check_jump_target(
- ¤t_frame, bcs.bci(), bcs.get_offset_s4(), CHECK_VERIFY(this));
+ ¤t_frame, target, CHECK_VERIFY(this));
no_control_flow = true; break;
case Bytecodes::_tableswitch :
case Bytecodes::_lookupswitch :
@@ -2102,14 +2107,15 @@ void ClassVerifier::verify_switch(
}
}
}
- stackmap_table->check_jump_target(current_frame, bci, default_offset, CHECK_VERIFY(this));
+ int target = bci + default_offset;
+ stackmap_table->check_jump_target(current_frame, target, CHECK_VERIFY(this));
for (int i = 0; i < keys; i++) {
// Because check_jump_target() may safepoint, the bytecode could have
// moved, which means 'aligned_bcp' is no good and needs to be recalculated.
aligned_bcp = (address)round_to((intptr_t)(bcs->bcp() + 1), jintSize);
- int offset = (jint)Bytes::get_Java_u4(aligned_bcp+(3+i*delta)*jintSize);
+ target = bci + (jint)Bytes::get_Java_u4(aligned_bcp+(3+i*delta)*jintSize);
stackmap_table->check_jump_target(
- current_frame, bci, offset, CHECK_VERIFY(this));
+ current_frame, target, CHECK_VERIFY(this));
}
NOT_PRODUCT(aligned_bcp = NULL); // no longer valid at this point
}
@@ -2370,13 +2376,8 @@ bool ClassVerifier::ends_in_athrow(u4 start_bc_offset) {
break;
case Bytecodes::_goto:
- case Bytecodes::_goto_w: {
- int offset = (opcode == Bytecodes::_goto ? bcs.get_offset_s2() : bcs.get_offset_s4());
- int min_offset = -1 * max_method_code_size;
- // Check offset for overflow
- if (offset < min_offset || offset > max_method_code_size) return false;
-
- target = bci + offset;
+ case Bytecodes::_goto_w:
+ target = (opcode == Bytecodes::_goto ? bcs.dest() : bcs.dest_w());
if (visited_branches->contains(bci)) {
if (bci_stack->is_empty()) {
if (handler_stack->is_empty()) {
@@ -2397,7 +2398,6 @@ bool ClassVerifier::ends_in_athrow(u4 start_bc_offset) {
visited_branches->append(bci);
}
break;
- }
// Check that all switch alternatives end in 'athrow' bytecodes. Since it
// is difficult to determine where each switch alternative ends, parse
@@ -2434,10 +2434,7 @@ bool ClassVerifier::ends_in_athrow(u4 start_bc_offset) {
// Push the switch alternatives onto the stack.
for (int i = 0; i < keys; i++) {
- int min_offset = -1 * max_method_code_size;
- int offset = (jint)Bytes::get_Java_u4(aligned_bcp+(3+i*delta)*jintSize);
- if (offset < min_offset || offset > max_method_code_size) return false;
- u4 target = bci + offset;
+ u4 target = bci + (jint)Bytes::get_Java_u4(aligned_bcp+(3+i*delta)*jintSize);
if (target > code_length) return false;
bci_stack->push(target);
}
diff --git a/hotspot/src/share/vm/interpreter/bytecodeStream.hpp b/hotspot/src/share/vm/interpreter/bytecodeStream.hpp
index 20f38950e1..b814b88d5d 100644
--- a/hotspot/src/share/vm/interpreter/bytecodeStream.hpp
+++ b/hotspot/src/share/vm/interpreter/bytecodeStream.hpp
@@ -121,23 +121,8 @@ class BaseBytecodeStream: StackObj {
void set_next_bci(int bci) { assert(0 <= bci && bci <= method()->code_size(), "illegal bci"); _next_bci = bci; }
// Bytecode-specific attributes
- int get_offset_s2() const { return bytecode().get_offset_s2(raw_code()); }
- int get_offset_s4() const { return bytecode().get_offset_s4(raw_code()); }
-
- // These methods are not safe to use before or during verification as they may
- // have large offsets and cause overflows
- int dest() const {
- int min_offset = -1 * max_method_code_size;
- int offset = bytecode().get_offset_s2(raw_code());
- guarantee(offset >= min_offset && offset <= max_method_code_size, "must be");
- return bci() + offset;
- }
- int dest_w() const {
- int min_offset = -1 * max_method_code_size;
- int offset = bytecode().get_offset_s4(raw_code());
- guarantee(offset >= min_offset && offset <= max_method_code_size, "must be");
- return bci() + offset;
- }
+ int dest() const { return bci() + bytecode().get_offset_s2(raw_code()); }
+ int dest_w() const { return bci() + bytecode().get_offset_s4(raw_code()); }
// One-byte indices.
int get_index_u1() const { assert_raw_index_size(1); return *(jubyte*)(bcp()+1); }
diff --git a/hotspot/src/share/vm/oops/method.cpp b/hotspot/src/share/vm/oops/method.cpp
index 7a63f3632e..9e58c01268 100644
--- a/hotspot/src/share/vm/oops/method.cpp
+++ b/hotspot/src/share/vm/oops/method.cpp
@@ -1903,6 +1903,9 @@ bool Method::is_method_id(jmethodID mid) {
Method* Method::checked_resolve_jmethod_id(jmethodID mid) {
if (mid == NULL) return NULL;
+ if (!Method::is_method_id(mid)) {
+ return NULL;
+ }
Method* o = resolve_jmethod_id(mid);
if (o == NULL || o == JNIMethodBlock::_free_method || !((Metadata*)o)->is_method()) {
return NULL;
diff --git a/hotspot/src/share/vm/prims/jniCheck.cpp b/hotspot/src/share/vm/prims/jniCheck.cpp
index bf8fd91b8d..593ca8a1e3 100644
--- a/hotspot/src/share/vm/prims/jniCheck.cpp
+++ b/hotspot/src/share/vm/prims/jniCheck.cpp
@@ -468,11 +468,6 @@ Method* jniCheck::validate_jmethod_id(JavaThread* thr, jmethodID method_id) {
if (moop == NULL) {
ReportJNIFatalError(thr, fatal_wrong_class_or_method);
}
- // jmethodIDs are supposed to be weak handles in the class loader data,
- // but that can be expensive so check it last
- else if (!Method::is_method_id(method_id)) {
- ReportJNIFatalError(thr, fatal_non_weak_method);
- }
return moop;
}
diff --git a/hotspot/src/share/vm/runtime/semaphore.inline.hpp b/hotspot/src/share/vm/runtime/semaphore.inline.hpp
index 458bfca801..e1cd4c9f6e 100644
--- a/hotspot/src/share/vm/runtime/semaphore.inline.hpp
+++ b/hotspot/src/share/vm/runtime/semaphore.inline.hpp
@@ -25,7 +25,7 @@
#ifndef SHARE_VM_RUNTIME_SEMAPHORE_INLINE_HPP
#define SHARE_VM_RUNTIME_SEMAPHORE_INLINE_HPP
-#include "runtime/interfaceSupport.hpp"
+#include "runtime/interfaceSupport.inline.hpp"
#include "runtime/semaphore.hpp"
#include "runtime/thread.inline.hpp"
diff --git a/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java b/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java
index 217ad54b78..0f1a2262c3 100644
--- a/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java
+++ b/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathFactoryImpl.java
@@ -187,7 +187,6 @@ public class XPathFactoryImpl extends XPathFactory {
if (value && _featureManager != null) {
_featureManager.setFeature(JdkXmlFeatures.XmlFeature.ENABLE_EXTENSION_FUNCTION,
JdkXmlFeatures.State.FSP, false);
- _xmlSecMgr.setSecureProcessing(value);
}
// all done processing feature
diff --git a/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathImpl.java b/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathImpl.java
index cc82576670..8d15deaad3 100644
--- a/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathImpl.java
+++ b/jaxp/src/com/sun/org/apache/xpath/internal/jaxp/XPathImpl.java
@@ -20,7 +20,6 @@
package com.sun.org.apache.xpath.internal.jaxp;
-import javax.xml.XMLConstants;
import javax.xml.namespace.QName;
import javax.xml.namespace.NamespaceContext;
import javax.xml.xpath.XPathExpressionException;
@@ -181,10 +180,6 @@ public class XPathImpl implements javax.xml.xpath.XPath {
// so we really have to create a fresh DocumentBuilder every time we need one
// - KK
DocumentBuilderFactory dbf = JdkXmlUtils.getDOMFactory(overrideDefaultParser);
- if (xmlSecMgr != null && xmlSecMgr.isSecureProcessingSet()) {
- dbf.setFeature(XMLConstants.FEATURE_SECURE_PROCESSING,
- xmlSecMgr.isSecureProcessing());
- }
return dbf.newDocumentBuilder();
} catch (ParserConfigurationException e) {
// this should never happen with a well-behaving JAXP implementation.
diff --git a/jaxp/src/jdk/xml/internal/XMLSecurityManager.java b/jaxp/src/jdk/xml/internal/XMLSecurityManager.java
index 64de41f51f..2dd165757f 100644
--- a/jaxp/src/jdk/xml/internal/XMLSecurityManager.java
+++ b/jaxp/src/jdk/xml/internal/XMLSecurityManager.java
@@ -189,12 +189,6 @@ public final class XMLSecurityManager {
*/
boolean secureProcessing;
- /**
- * Flag indicating the secure processing is set explicitly through factories'
- * setFeature method and then the setSecureProcessing method
- */
- boolean secureProcessingSet;
-
/**
* States that determine if properties are set explicitly
*/
@@ -242,7 +236,6 @@ public final class XMLSecurityManager {
* Setting FEATURE_SECURE_PROCESSING explicitly
*/
public void setSecureProcessing(boolean secure) {
- secureProcessingSet = true;
secureProcessing = secure;
for (Limit limit : Limit.values()) {
if (secure) {
@@ -261,15 +254,6 @@ public final class XMLSecurityManager {
return secureProcessing;
}
- /**
- * Returns the state indicating whether the Secure Processing is set explicitly,
- * via factories' setFeature and then this class' setSecureProcessing method.
- * @return the state indicating whether the Secure Processing is set explicitly
- */
- public boolean isSecureProcessingSet() {
- return secureProcessingSet;
- }
-
/**
* Set limit by property name and state
* @param propertyName property name
diff --git a/jdk/make/data/cacerts/affirmtrustcommercialca b/jdk/make/data/cacerts/affirmtrustcommercialca
new file mode 100644
index 0000000000..5caddfd3a0
--- /dev/null
+++ b/jdk/make/data/cacerts/affirmtrustcommercialca
@@ -0,0 +1,27 @@
+Owner: CN=AffirmTrust Commercial, O=AffirmTrust, C=US
+Issuer: CN=AffirmTrust Commercial, O=AffirmTrust, C=US
+Serial number: 7777062726a9b17c
+Valid from: Fri Jan 29 14:06:06 GMT 2010 until: Tue Dec 31 14:06:06 GMT 2030
+Signature algorithm name: SHA256withRSA
+Subject Public Key Algorithm: 2048-bit RSA key
+Version: 3
+-----BEGIN CERTIFICATE-----
+MIIDTDCCAjSgAwIBAgIId3cGJyapsXwwDQYJKoZIhvcNAQELBQAwRDELMAkGA1UE
+BhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVz
+dCBDb21tZXJjaWFsMB4XDTEwMDEyOTE0MDYwNloXDTMwMTIzMTE0MDYwNlowRDEL
+MAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZp
+cm1UcnVzdCBDb21tZXJjaWFsMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKC
+AQEA9htPZwcroRX1BiLLHwGy43NFBkRJLLtJJRTWzsO3qyxPxkEylFf6EqdbDuKP
+Hx6GGaeqtS25Xw2Kwq+FNXkyLbscYjfysVtKPcrNcV/pQr6U6Mje+SJIZMblq8Yr
+ba0F8PrVC8+a5fBQpIs7R6UjW3p6+DM/uO+Zl+MgwdYoic+U+7lF7eNAFxHUdPAL
+MeIrJmqbTFeurCA+ukV6BfO9m2kVrn1OIGPENXY6BwLJN/3HR+7o8XYdcxXyl6S1
+yHp52UKqK39c/s4mT6NmgTWvRLpUHhwwMmWd5jyTXlBOeuM61G7MGvv50jeuJCqr
+VwMiKA1JdX+3KNp1v47j3A55MQIDAQABo0IwQDAdBgNVHQ4EFgQUnZPGU4teyq8/
+nx4P5ZmVvCT2lI8wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwDQYJ
+KoZIhvcNAQELBQADggEBAFis9AQOzcAN/wr91LoWXym9e2iZWEnStB03TX8nfUYG
+XUPGhi4+c7ImfU+TqbbEKpqrIZcUsd6M06uJFdhrJNTxFq7YpFzUf1GO7RgBsZNj
+vbz4YYCanrHOQnDiqX0GJX0nof5v7LMeJNrjS1UaADs1tDvZ110w/YETifLCBivt
+Z8SOyUOyXGsViQK8YvxO8rUzqrJv0wqiUOP2O+guRMLbZjipM1ZI8W0bM40NjD9g
+N53Tym1+NH4Nn3J2ixufcv1SNUFFApYvHLKac0khsUlHRUe072o0EclNmsxZt9YC
+nlpOZbWUrhvfKbAW8b8Angc6F2S1BLUjIZkKlTuXfO8=
+-----END CERTIFICATE-----
diff --git a/jdk/make/data/cacerts/affirmtrustnetworkingca b/jdk/make/data/cacerts/affirmtrustnetworkingca
new file mode 100644
index 0000000000..c773326d4b
--- /dev/null
+++ b/jdk/make/data/cacerts/affirmtrustnetworkingca
@@ -0,0 +1,27 @@
+Owner: CN=AffirmTrust Networking, O=AffirmTrust, C=US
+Issuer: CN=AffirmTrust Networking, O=AffirmTrust, C=US
+Serial number: 7c4f04391cd4992d
+Valid from: Fri Jan 29 14:08:24 GMT 2010 until: Tue Dec 31 14:08:24 GMT 2030
+Signature algorithm name: SHA1withRSA
+Subject Public Key Algorithm: 2048-bit RSA key
+Version: 3
+-----BEGIN CERTIFICATE-----
+MIIDTDCCAjSgAwIBAgIIfE8EORzUmS0wDQYJKoZIhvcNAQEFBQAwRDELMAkGA1UE
+BhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVz
+dCBOZXR3b3JraW5nMB4XDTEwMDEyOTE0MDgyNFoXDTMwMTIzMTE0MDgyNFowRDEL
+MAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZp
+cm1UcnVzdCBOZXR3b3JraW5nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKC
+AQEAtITMMxcua5Rsa2FSoOujz3mUTOWUgJnLVWREZY9nZOIG41w3SfYvm4SEHi3y
+YJ0wTsyEheIszx6e/jarM3c1RNg1lho9Nuh6DtjVR6FqaYvZ/Ls6rnla1fTWcbua
+kCNrmreIdIcMHl+5ni36q1Mr3Lt2PpNMCAiMHqIjHNRqrSK6mQEubWXLviRmVSRL
+QESxG9fhwoXA3hA/Pe24/PHxI1Pcv2WXb9n5QHGNfb2V1M6+oF4nI979ptAmDgAp
+6zxG8D1gvz9Q0twmQVGeFDdCBKNwV6gbh+0t+nvujArjqWaJGctB+d1ENmHP4ndG
+yH329JKBNv3bNPFyfvMMFr20FQIDAQABo0IwQDAdBgNVHQ4EFgQUBx/S55zawm6i
+QLSwelAQUHTEyL0wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwDQYJ
+KoZIhvcNAQEFBQADggEBAIlXshZ6qML91tmbmzTCnLQyFE2npN/svqe++EPbkTfO
+tDIuUFUaNU52Q3Eg75N3ThVwLofDwR1t3Mu1J9QsVtFSUzpE0nPIxBsFZVpikpzu
+QY0x2+c06lkh1QF612S4ZDnNye2v7UsDSKegmQGA3GWjNq5lWUhPgkvIZfFXHeVZ
+Lgo/bNjR9eUJtGxUAArgFU2HdW23WJZa3W3SAKD0m0i+wzekujbgfIeFlxoVot4u
+olu9rxj5kFDNcFn4J2dHy8egBzp90SxdbBk6ZrV9/ZFvgrG+CJPbFEfxojfHRZ48
+x3evZKiT3/Zpg4Jg8klCNO1aAFSFHBY2kgxc+qatv9s=
+-----END CERTIFICATE-----
diff --git a/jdk/make/data/cacerts/affirmtrustpremiumca b/jdk/make/data/cacerts/affirmtrustpremiumca
new file mode 100644
index 0000000000..275b495a25
--- /dev/null
+++ b/jdk/make/data/cacerts/affirmtrustpremiumca
@@ -0,0 +1,38 @@
+Owner: CN=AffirmTrust Premium, O=AffirmTrust, C=US
+Issuer: CN=AffirmTrust Premium, O=AffirmTrust, C=US
+Serial number: 6d8c1446b1a60aee
+Valid from: Fri Jan 29 14:10:36 GMT 2010 until: Mon Dec 31 14:10:36 GMT 2040
+Signature algorithm name: SHA384withRSA
+Subject Public Key Algorithm: 4096-bit RSA key
+Version: 3
+-----BEGIN CERTIFICATE-----
+MIIFRjCCAy6gAwIBAgIIbYwURrGmCu4wDQYJKoZIhvcNAQEMBQAwQTELMAkGA1UE
+BhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MRwwGgYDVQQDDBNBZmZpcm1UcnVz
+dCBQcmVtaXVtMB4XDTEwMDEyOTE0MTAzNloXDTQwMTIzMTE0MTAzNlowQTELMAkG
+A1UEBhMCVVMxFDASBgNVBAoMC0FmZmlybVRydXN0MRwwGgYDVQQDDBNBZmZpcm1U
+cnVzdCBQcmVtaXVtMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAxBLf
+qV/+Qd3d9Z+K4/as4Tx4mrzY8H96oDMq3I0gW64tb+eT2TZwamjPjlGjhVtnBKAQ
+JG9dKILBl1fYSCkTtuG+kU3fhQxTGJoeJKJPj/CihQvL9Cl/0qRY7iZNyaqoe5rZ
++jjeRFcV5fiMyNlI4g0WJx0eyIOFJbe6qlVBzAMiSy2RjYvmia9mx+n/K+k8rNrS
+s8PhaJyJ+HoAVt70VZVs+7pk3WKL3wt3MutizCaam7uqYoNMtAZ6MMgpv+0GTZe5
+HMQxK9VfvFMSF5yZVylmd2EhMQcuJUmdGPLu8ytxjLW6OQdJd/zvLpKQBY0tL3d7
+70O/Nbua2Plzpyzy0FfuKE4mX4+QaAkvuPjcBukumj5Rp9EixAqnOEhss/n/fauG
+V+O61oV4d7pD6kh/9ti+I20ev9E2bFhc8e6kGVQa9QPSdubhjL08s9NIS+LI+H+S
+qHZGnEJlPqQewQcDWkYtuJfzt9WyVSHvutxMAJf7FJUnM7/oQ0dG0giZFmA7mn7S
+5u046uwBHjxIVkkJx0w3AJ6IDsBz4W9m6XJHMD4Q5QsDyZpCAGzFlH5hxIrff4Ia
+C1nEWTJ3s7xgaVY5/bQGeyzWZDbZvUjthB9+pSKPKrhC9IK31FOQeE4tGv2Bb0TX
+OwF0lkLgAOIua+rF7nKsu7/+6qqo+Nz2snmKtmcCAwEAAaNCMEAwHQYDVR0OBBYE
+FJ3AZ6YMItkm9UWrpmVSESfYRaxjMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/
+BAQDAgEGMA0GCSqGSIb3DQEBDAUAA4ICAQCzV00QYk465KzquByvMiPIs0laUZx2
+KI15qldGF9X1Uva3ROgIRL8YhNILgM3FEv0AVQVhh0HctSSePMTYyPtwni94loMg
+Nt58D2kTiKV1NpgIpsbfrM7jWNa3Pt668+s0QNiigfV4Py/VpfzZotReBA4Xrf5B
+8OWycvpEgjNC6C1Y91aMYj+6QrCcDFx+LmUmXFNPALJ4fqENmS2NuB2OosSw/WDQ
+MKSOyARiqcTtNd56l+0OOF6SL5Nwpamcb6d9Ex1+xghIsV5n61EIJenmJWtSKZGc
+0jlzCFfemQa0W50QBuHCAKi4HEoCChTQwUHK+4w1IX2COPKpVJEZNZOUbWo6xbLQ
+u4mGk+ibyQ86p3q4ofB4Rvr8Ny/lioTz3/4E2aFooC8k4gmVBtWVyuEklut89pMF
+u+1z6S3RdTnX5yTb2E5fQ4+e0BQ5v1VwSJlXMbSc7kqYA5YwH2AG7hsj/oFgIxpH
+YoWlzBk0gG+zrBrjn/B7SK3VAdlntqlyk+otZrWyuOQ9PLLvTIzq6we/qzWaVYa8
+GKa1qF60g2xraUDTn9zxw2lrueFtCfTxqlB2Cnp9ehehVZZCmTEJ3WARjQUwfuaO
+RtGdFNrHF+QFlozEJLUbzxQHskD4o55BhrwE0GuWyCqANP2/7waj3VjFhT0+j/6e
+KeC2uAloGRwYQw==
+-----END CERTIFICATE-----
diff --git a/jdk/make/data/cacerts/affirmtrustpremiumeccca b/jdk/make/data/cacerts/affirmtrustpremiumeccca
new file mode 100644
index 0000000000..d0fcc1e779
--- /dev/null
+++ b/jdk/make/data/cacerts/affirmtrustpremiumeccca
@@ -0,0 +1,20 @@
+Owner: CN=AffirmTrust Premium ECC, O=AffirmTrust, C=US
+Issuer: CN=AffirmTrust Premium ECC, O=AffirmTrust, C=US
+Serial number: 7497258ac73f7a54
+Valid from: Fri Jan 29 14:20:24 GMT 2010 until: Mon Dec 31 14:20:24 GMT 2040
+Signature algorithm name: SHA384withECDSA
+Subject Public Key Algorithm: 384-bit EC (secp384r1) key
+Version: 3
+-----BEGIN CERTIFICATE-----
+MIIB/jCCAYWgAwIBAgIIdJclisc/elQwCgYIKoZIzj0EAwMwRTELMAkGA1UEBhMC
+VVMxFDASBgNVBAoMC0FmZmlybVRydXN0MSAwHgYDVQQDDBdBZmZpcm1UcnVzdCBQ
+cmVtaXVtIEVDQzAeFw0xMDAxMjkxNDIwMjRaFw00MDEyMzExNDIwMjRaMEUxCzAJ
+BgNVBAYTAlVTMRQwEgYDVQQKDAtBZmZpcm1UcnVzdDEgMB4GA1UEAwwXQWZmaXJt
+VHJ1c3QgUHJlbWl1bSBFQ0MwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQNMF4bFZ0D
+0KF5Nbc6PJJ6yhUczWLznCZcBz3lVPqj1swS6vQUX+iOGasvLkjmrBhDeKzQN8O9
+ss0s5kfiGuZjuD0uL3jET9v0D6RoTFVya5UdThhClXjMNzyR4ptlKymjQjBAMB0G
+A1UdDgQWBBSaryl6wBE1NSZRMADDav5A1a7WPDAPBgNVHRMBAf8EBTADAQH/MA4G
+A1UdDwEB/wQEAwIBBjAKBggqhkjOPQQDAwNnADBkAjAXCfOHiFBar8jAQr9HX/Vs
+aobgxCd05DhT1wV/GzTjxi+zygk8N53X57hG8f2h4nECMEJZh0PUUd+60wkyWs6I
+flc9nF9Ca/UHLbXwgpP5WW+uZPpY5Yse42O+tYHNbwKMeQ==
+-----END CERTIFICATE-----
diff --git a/jdk/make/src/classes/build/tools/generatecurrencydata/GenerateCurrencyData.java b/jdk/make/src/classes/build/tools/generatecurrencydata/GenerateCurrencyData.java
index d599d9744f..c16222b795 100644
--- a/jdk/make/src/classes/build/tools/generatecurrencydata/GenerateCurrencyData.java
+++ b/jdk/make/src/classes/build/tools/generatecurrencydata/GenerateCurrencyData.java
@@ -120,7 +120,7 @@ public class GenerateCurrencyData {
private static final int maxOtherCurrencies = 128;
private static int otherCurrenciesCount = 0;
- private static String[] otherCurrencies = new String[maxOtherCurrencies];
+ private static StringBuffer otherCurrencies = new StringBuffer();
private static int[] otherCurrenciesDefaultFractionDigits = new int[maxOtherCurrencies];
private static int[] otherCurrenciesNumericCode= new int[maxOtherCurrencies];
@@ -323,7 +323,10 @@ public class GenerateCurrencyData {
if (otherCurrenciesCount == maxOtherCurrencies) {
throw new RuntimeException("too many other currencies");
}
- otherCurrencies[otherCurrenciesCount] = currencyCode;
+ if (otherCurrencies.length() > 0) {
+ otherCurrencies.append('-');
+ }
+ otherCurrencies.append(currencyCode);
otherCurrenciesDefaultFractionDigits[otherCurrenciesCount] = getDefaultFractionDigits(currencyCode);
otherCurrenciesNumericCode[otherCurrenciesCount] = getNumericCode(currencyCode);
otherCurrenciesCount++;
@@ -352,41 +355,35 @@ public class GenerateCurrencyData {
out.writeInt(Integer.parseInt(dataVersion));
writeIntArray(mainTable, mainTable.length);
out.writeInt(specialCaseCount);
- writeSpecialCaseEntries();
+ writeLongArray(specialCaseCutOverTimes, specialCaseCount);
+ writeStringArray(specialCaseOldCurrencies, specialCaseCount);
+ writeStringArray(specialCaseNewCurrencies, specialCaseCount);
+ writeIntArray(specialCaseOldCurrenciesDefaultFractionDigits, specialCaseCount);
+ writeIntArray(specialCaseNewCurrenciesDefaultFractionDigits, specialCaseCount);
+ writeIntArray(specialCaseOldCurrenciesNumericCode, specialCaseCount);
+ writeIntArray(specialCaseNewCurrenciesNumericCode, specialCaseCount);
out.writeInt(otherCurrenciesCount);
- writeOtherCurrencies();
+ out.writeUTF(otherCurrencies.toString());
+ writeIntArray(otherCurrenciesDefaultFractionDigits, otherCurrenciesCount);
+ writeIntArray(otherCurrenciesNumericCode, otherCurrenciesCount);
}
private static void writeIntArray(int[] ia, int count) throws IOException {
- for (int i = 0; i < count; i++) {
+ for (int i = 0; i < count; i ++) {
out.writeInt(ia[i]);
}
}
- private static void writeSpecialCaseEntries() throws IOException {
- for (int index = 0; index < specialCaseCount; index++) {
- out.writeLong(specialCaseCutOverTimes[index]);
- String str = (specialCaseOldCurrencies[index] != null)
- ? specialCaseOldCurrencies[index] : "";
- out.writeUTF(str);
- str = (specialCaseNewCurrencies[index] != null)
- ? specialCaseNewCurrencies[index] : "";
- out.writeUTF(str);
- out.writeInt(specialCaseOldCurrenciesDefaultFractionDigits[index]);
- out.writeInt(specialCaseNewCurrenciesDefaultFractionDigits[index]);
- out.writeInt(specialCaseOldCurrenciesNumericCode[index]);
- out.writeInt(specialCaseNewCurrenciesNumericCode[index]);
+ private static void writeLongArray(long[] la, int count) throws IOException {
+ for (int i = 0; i < count; i ++) {
+ out.writeLong(la[i]);
}
}
- private static void writeOtherCurrencies() throws IOException {
- for (int index = 0; index < otherCurrenciesCount; index++) {
- String str = (otherCurrencies[index] != null)
- ? otherCurrencies[index] : "";
+ private static void writeStringArray(String[] sa, int count) throws IOException {
+ for (int i = 0; i < count; i ++) {
+ String str = (sa[i] != null) ? sa[i] : "";
out.writeUTF(str);
- out.writeInt(otherCurrenciesDefaultFractionDigits[index]);
- out.writeInt(otherCurrenciesNumericCode[index]);
}
}
-
}
diff --git a/jdk/src/aix/native/java/net/aix_close.c b/jdk/src/aix/native/java/net/aix_close.c
index 5bf798aba1..90d57b42f0 100644
--- a/jdk/src/aix/native/java/net/aix_close.c
+++ b/jdk/src/aix/native/java/net/aix_close.c
@@ -55,7 +55,6 @@
#include <errno.h>
#include <sys/poll.h>
-#include "jvm.h"
/*
* Stack allocated by thread when doing blocking operation
@@ -377,61 +376,61 @@ int NET_SocketClose(int fd) {
/************** Basic I/O operations here ***************/
/*
- * Macro to perform a blocking IO operation.
- * If interrupted by signal (other than our wakeup signal), and if RETRY is true,
- * then restarts automatically
+ * Macro to perform a blocking IO operation. Restarts
+ * automatically if interrupted by signal (other than
+ * our wakeup signal)
*/
-#define BLOCKING_IO_RETURN_INT(FD, FUNC, RETRY) { \
- int ret; \
- threadEntry_t self; \
- fdEntry_t *fdEntry = getFdEntry(FD); \
- if (fdEntry == NULL) { \
- errno = EBADF; \
- return -1; \
- } \
- do { \
- startOp(fdEntry, &self); \
- ret = FUNC; \
- endOp(fdEntry, &self); \
- } while ((RETRY) && ret == -1 && errno == EINTR); \
- return ret; \
+#define BLOCKING_IO_RETURN_INT(FD, FUNC) { \
+ int ret; \
+ threadEntry_t self; \
+ fdEntry_t *fdEntry = getFdEntry(FD); \
+ if (fdEntry == NULL) { \
+ errno = EBADF; \
+ return -1; \
+ } \
+ do { \
+ startOp(fdEntry, &self); \
+ ret = FUNC; \
+ endOp(fdEntry, &self); \
+ } while (ret == -1 && errno == EINTR); \
+ return ret; \
}
int NET_Read(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0) );
}
int NET_NonBlockingRead(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT(s, recv(s, buf, len, MSG_NONBLOCK), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT(s, recv(s, buf, len, MSG_NONBLOCK));
}
int NET_ReadV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, readv(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, readv(s, vector, count) );
}
int NET_RecvFrom(int s, void *buf, int len, unsigned int flags,
struct sockaddr *from, int *fromlen) {
socklen_t socklen = *fromlen;
- BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, &socklen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, &socklen) );
*fromlen = socklen;
}
int NET_Send(int s, void *msg, int len, unsigned int flags) {
- BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags) );
}
int NET_WriteV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, writev(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, writev(s, vector, count) );
}
int NET_SendTo(int s, const void *msg, int len, unsigned int
flags, const struct sockaddr *to, int tolen) {
- BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen) );
}
int NET_Accept(int s, struct sockaddr *addr, int *addrlen) {
socklen_t socklen = *addrlen;
- BLOCKING_IO_RETURN_INT( s, accept(s, addr, &socklen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, accept(s, addr, &socklen) );
*addrlen = socklen;
}
@@ -491,13 +490,13 @@ int NET_Connect(int s, struct sockaddr *addr, int addrlen) {
#ifndef USE_SELECT
int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
- BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout), JNI_FALSE );
+ BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout) );
}
#else
int NET_Select(int s, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds, struct timeval *timeout) {
BLOCKING_IO_RETURN_INT( s-1,
- select(s, readfds, writefds, exceptfds, timeout), JNI_TRUE );
+ select(s, readfds, writefds, exceptfds, timeout) );
}
#endif
diff --git a/jdk/src/share/classes/com/sun/java/swing/SwingUtilities3.java b/jdk/src/share/classes/com/sun/java/swing/SwingUtilities3.java
index 624733ac41..b50fb2ae1b 100644
--- a/jdk/src/share/classes/com/sun/java/swing/SwingUtilities3.java
+++ b/jdk/src/share/classes/com/sun/java/swing/SwingUtilities3.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2002, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -36,20 +36,11 @@ import java.util.concurrent.Callable;
import java.applet.Applet;
import java.awt.AWTEvent;
import java.awt.EventQueue;
-import java.awt.Color;
import java.awt.Component;
import java.awt.Container;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.Rectangle;
import java.awt.Window;
-import javax.swing.ButtonModel;
-import javax.swing.Icon;
import javax.swing.JComponent;
-import javax.swing.JMenu;
import javax.swing.RepaintManager;
-import sun.swing.MenuItemLayoutHelper;
-import sun.swing.SwingUtilities2;
/**
* A collection of utility methods for Swing.
@@ -122,119 +113,6 @@ public class SwingUtilities3 {
return Boolean.TRUE == vsyncedMap.get(rootContainer);
}
- public static void applyInsets(Rectangle rect, Insets insets) {
- if (insets != null) {
- rect.x += insets.left;
- rect.y += insets.top;
- rect.width -= (insets.right + rect.x);
- rect.height -= (insets.bottom + rect.y);
- }
- }
-
- public static void paintCheckIcon(Graphics g, MenuItemLayoutHelper lh,
- MenuItemLayoutHelper.LayoutResult lr,
- Color holdc, Color foreground) {
- if (lh.getCheckIcon() != null) {
- ButtonModel model = lh.getMenuItem().getModel();
- if (model.isArmed() || (lh.getMenuItem() instanceof JMenu
- && model.isSelected())) {
- g.setColor(foreground);
- } else {
- g.setColor(holdc);
- }
- if (lh.useCheckAndArrow()) {
- lh.getCheckIcon().paintIcon(lh.getMenuItem(), g,
- lr.getCheckRect().x, lr.getCheckRect().y);
- }
- g.setColor(holdc);
- }
- }
-
- public static void paintIcon(Graphics g, MenuItemLayoutHelper lh,
- MenuItemLayoutHelper.LayoutResult lr, Color holdc) {
- if (lh.getIcon() != null) {
- Icon icon;
- ButtonModel model = lh.getMenuItem().getModel();
- if (!model.isEnabled()) {
- icon = lh.getMenuItem().getDisabledIcon();
- } else if (model.isPressed() && model.isArmed()) {
- icon = lh.getMenuItem().getPressedIcon();
- if (icon == null) {
- // Use default icon
- icon = lh.getMenuItem().getIcon();
- }
- } else {
- icon = lh.getMenuItem().getIcon();
- }
-
- if (icon != null) {
- icon.paintIcon(lh.getMenuItem(), g, lr.getIconRect().x,
- lr.getIconRect().y);
- g.setColor(holdc);
- }
- }
- }
-
-
- public static void paintAccText(Graphics g, MenuItemLayoutHelper lh,
- MenuItemLayoutHelper.LayoutResult lr,
- Color disabledForeground,
- Color acceleratorSelectionForeground,
- Color acceleratorForeground) {
- if (!lh.getAccText().isEmpty()) {
- ButtonModel model = lh.getMenuItem().getModel();
- g.setFont(lh.getAccFontMetrics().getFont());
- if (!model.isEnabled()) {
-
- // paint the accText disabled
- if (disabledForeground != null) {
- g.setColor(disabledForeground);
- SwingUtilities2.drawString(lh.getMenuItem(), g,
- lh.getAccText(), lr.getAccRect().x,
- lr.getAccRect().y + lh.getAccFontMetrics().getAscent());
- } else {
- g.setColor(lh.getMenuItem().getBackground().brighter());
- SwingUtilities2.drawString(lh.getMenuItem(), g,
- lh.getAccText(), lr.getAccRect().x,
- lr.getAccRect().y + lh.getAccFontMetrics().getAscent());
- g.setColor(lh.getMenuItem().getBackground().darker());
- SwingUtilities2.drawString(lh.getMenuItem(), g,
- lh.getAccText(), lr.getAccRect().x - 1,
- lr.getAccRect().y + lh.getFontMetrics().getAscent() - 1);
- }
- } else {
-
- // paint the accText normally
- if (model.isArmed()
- || (lh.getMenuItem() instanceof JMenu
- && model.isSelected())) {
- g.setColor(acceleratorSelectionForeground);
- } else {
- g.setColor(acceleratorForeground);
- }
- SwingUtilities2.drawString(lh.getMenuItem(), g, lh.getAccText(),
- lr.getAccRect().x, lr.getAccRect().y +
- lh.getAccFontMetrics().getAscent());
- }
- }
- }
-
- public static void paintArrowIcon(Graphics g, MenuItemLayoutHelper lh,
- MenuItemLayoutHelper.LayoutResult lr,
- Color foreground) {
- if (lh.getArrowIcon() != null) {
- ButtonModel model = lh.getMenuItem().getModel();
- if (model.isArmed() || (lh.getMenuItem() instanceof JMenu
- && model.isSelected())) {
- g.setColor(foreground);
- }
- if (lh.useCheckAndArrow()) {
- lh.getArrowIcon().paintIcon(lh.getMenuItem(), g,
- lr.getArrowRect().x, lr.getArrowRect().y);
- }
- }
- }
-
/**
* Returns delegate {@code RepaintManager} for {@code component} hierarchy.
*/
diff --git a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java
index 9efdc860d6..ab1a1bce0b 100644
--- a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java
+++ b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -74,26 +74,6 @@ public class WindowsCheckBoxMenuItemUI extends BasicCheckBoxMenuItemUI {
}
super.paintBackground(g, menuItem, bgColor);
}
-
- /**
- * Paint MenuItem.
- */
- protected void paintMenuItem(Graphics g, JComponent c,
- Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground,
- int defaultTextIconGap) {
- if (WindowsMenuItemUI.isVistaPainting()) {
- WindowsMenuItemUI.paintMenuItem(accessor, g, c, checkIcon,
- arrowIcon, background, foreground,
- disabledForeground, acceleratorSelectionForeground,
- acceleratorForeground, defaultTextIconGap,
- menuItem, getPropertyPrefix());
- return;
- }
- super.paintMenuItem(g, c, checkIcon, arrowIcon, background,
- foreground, defaultTextIconGap);
- }
-
/**
* Method which renders the text of the current menu item.
* <p>
diff --git a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java
index 7fda45b254..90bdc92938 100644
--- a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java
+++ b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 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
@@ -785,7 +785,6 @@ public class WindowsIconFactory implements Serializable
}
assert menuItem == null || c == menuItem;
Icon icon = getIcon();
-
if (type == JCheckBoxMenuItem.class
|| type == JRadioButtonMenuItem.class) {
AbstractButton b = (AbstractButton) c;
@@ -809,18 +808,19 @@ public class WindowsIconFactory implements Serializable
}
XPStyle xp = XPStyle.getXP();
if (xp != null) {
- Skin skin = xp.getSkin(c, part);
- if (icon == null || icon.getIconHeight() <= 16) {
+ Skin skin;
+ skin = xp.getSkin(c, backgroundPart);
+ skin.paintSkin(g, x, y,
+ getIconWidth(), getIconHeight(), backgroundState);
+ if (icon == null) {
+ skin = xp.getSkin(c, part);
skin.paintSkin(g, x + OFFSET, y + OFFSET, state);
- } else {
- skin.paintSkin(g, x + OFFSET, y + icon.getIconHeight() / 2, state);
}
}
}
}
if (icon != null) {
- icon.paintIcon(c, g, x + VistaMenuItemCheckIconFactory.getIconWidth(),
- y + OFFSET);
+ icon.paintIcon(c, g, x + OFFSET, y + OFFSET);
}
}
private static WindowsMenuItemUIAccessor getAccessor(
diff --git a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java
index c74f0490ee..dddbeeb507 100644
--- a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java
+++ b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2014, 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
@@ -31,11 +31,9 @@ import javax.swing.plaf.*;
import javax.swing.plaf.basic.*;
import sun.swing.SwingUtilities2;
-import sun.swing.MenuItemLayoutHelper;
import com.sun.java.swing.plaf.windows.TMSchema.*;
import com.sun.java.swing.plaf.windows.XPStyle.*;
-import com.sun.java.swing.SwingUtilities3;
/**
* Windows rendition of the component.
@@ -49,8 +47,8 @@ import com.sun.java.swing.SwingUtilities3;
*
* @author Igor Kushnirskiy
*/
-public class WindowsMenuItemUI extends BasicMenuItemUI {
+public class WindowsMenuItemUI extends BasicMenuItemUI {
final WindowsMenuItemUIAccessor accessor =
new WindowsMenuItemUIAccessor() {
@@ -70,112 +68,6 @@ public class WindowsMenuItemUI extends BasicMenuItemUI {
return new WindowsMenuItemUI();
}
- protected void installDefaults() {
- super.installDefaults();
- String prefix = getPropertyPrefix();
-
- if (acceleratorSelectionForeground == null ||
- acceleratorSelectionForeground instanceof UIResource) {
- acceleratorSelectionForeground =
- UIManager.getColor(prefix + ".acceleratorSelectionForeground");
- }
- if (acceleratorForeground == null ||
- acceleratorForeground instanceof UIResource) {
- acceleratorForeground =
- UIManager.getColor(prefix + ".acceleratorForeground");
- }
- if (disabledForeground == null ||
- disabledForeground instanceof UIResource) {
- disabledForeground =
- UIManager.getColor(prefix + ".disabledForeground");
- }
- }
-
-
- protected void paintMenuItem(Graphics g, JComponent c,
- Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground,
- int defaultTextIconGap) {
- if (WindowsMenuItemUI.isVistaPainting()) {
- WindowsMenuItemUI.paintMenuItem(accessor, g, c, checkIcon,
- arrowIcon, background, foreground,
- disabledForeground, acceleratorSelectionForeground,
- acceleratorForeground, defaultTextIconGap, menuItem,
- getPropertyPrefix());
- return;
- }
- super.paintMenuItem(g, c, checkIcon, arrowIcon, background,
- foreground, defaultTextIconGap);
- }
-
- static void paintMenuItem(WindowsMenuItemUIAccessor accessor, Graphics g,
- JComponent c, Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground,
- Color disabledForeground,
- Color acceleratorSelectionForeground,
- Color acceleratorForeground,
- int defaultTextIconGap, JMenuItem menuItem, String prefix) {
- // Save original graphics font and color
- Font holdf = g.getFont();
- Color holdc = g.getColor();
-
- JMenuItem mi = (JMenuItem) c;
- g.setFont(mi.getFont());
-
- Rectangle viewRect = new Rectangle(0, 0, mi.getWidth(), mi.getHeight());
- SwingUtilities3.applyInsets(viewRect, mi.getInsets());
-
- String acceleratorDelimiter =
- UIManager.getString("MenuItem.acceleratorDelimiter");
- if (acceleratorDelimiter == null) { acceleratorDelimiter = "+"; }
- Font acceleratorFont = UIManager.getFont("MenuItem.acceleratorFont");
- if (acceleratorFont == null) {
- acceleratorFont = UIManager.getFont("MenuItem.font");
- }
-
- MenuItemLayoutHelper lh = new MenuItemLayoutHelper(mi, checkIcon,
- arrowIcon, viewRect, defaultTextIconGap, acceleratorDelimiter,
- mi.getComponentOrientation().isLeftToRight(), mi.getFont(),
- acceleratorFont, MenuItemLayoutHelper.useCheckAndArrow(menuItem),
- prefix);
- MenuItemLayoutHelper.LayoutResult lr = lh.layoutMenuItem();
-
- paintBackground(accessor, g, mi, background);
- SwingUtilities3.paintCheckIcon(g, lh, lr, holdc, foreground);
- SwingUtilities3.paintIcon(g, lh, lr, holdc);
-
- if (lh.getCheckIcon() != null && lh.useCheckAndArrow()) {
- Rectangle rect = lr.getTextRect();
-
- rect.x += lh.getAfterCheckIconGap();
-
- lr.setTextRect(rect);
- }
- if (!lh.getText().isEmpty()) {
- if (lh.getHtmlView() != null) {
- // Text is HTML
- lh.getHtmlView().paint(g, lr.getTextRect());
- } else {
- // Text isn't HTML
- paintText(accessor, g, lh.getMenuItem(),
- lr.getTextRect(), lh.getText());
- }
- }
- if (lh.getCheckIcon() != null && lh.useCheckAndArrow()) {
- Rectangle rect = lr.getAccRect();
- rect.x += lh.getAfterCheckIconGap();
- lr.setAccRect(rect);
- }
- SwingUtilities3.paintAccText(g, lh, lr, disabledForeground,
- acceleratorSelectionForeground,
- acceleratorForeground);
- SwingUtilities3.paintArrowIcon(g, lh, lr, foreground);
-
- // Restore original graphics font and color
- g.setColor(holdc);
- g.setFont(holdf);
- }
-
/**
* Method which renders the text of the current menu item.
* <p>
diff --git a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java
index c5bd54edf2..a2e7795cfe 100644
--- a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java
+++ b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2007, 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
@@ -123,26 +123,6 @@ public class WindowsMenuUI extends BasicMenuUI {
hotTrackingOn = (obj instanceof Boolean) ? (Boolean)obj : true;
}
- /**
- * Paint MenuItem.
- */
- protected void paintMenuItem(Graphics g, JComponent c,
- Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground,
- int defaultTextIconGap) {
- if (WindowsMenuItemUI.isVistaPainting()) {
- WindowsMenuItemUI.paintMenuItem(accessor, g, c, checkIcon, arrowIcon,
- background, foreground,
- disabledForeground, acceleratorSelectionForeground,
- acceleratorForeground, defaultTextIconGap, menuItem,
- getPropertyPrefix());
- return;
- }
- super.paintMenuItem(g, c, checkIcon, arrowIcon, background,
- foreground, defaultTextIconGap);
- }
-
-
/**
* Draws the background of the menu.
* @since 1.4
diff --git a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java
index 41bcfb7b86..c43876f38b 100644
--- a/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java
+++ b/jdk/src/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -74,25 +74,6 @@ public class WindowsRadioButtonMenuItemUI extends BasicRadioButtonMenuItemUI {
super.paintBackground(g, menuItem, bgColor);
}
- /**
- * Paint MenuItem.
- */
- protected void paintMenuItem(Graphics g, JComponent c,
- Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground,
- int defaultTextIconGap) {
- if (WindowsMenuItemUI.isVistaPainting()) {
- WindowsMenuItemUI.paintMenuItem(accessor, g, c, checkIcon,
- arrowIcon, background, foreground,
- disabledForeground, acceleratorSelectionForeground,
- acceleratorForeground, defaultTextIconGap,
- menuItem, getPropertyPrefix());
- return;
- }
- super.paintMenuItem(g, c, checkIcon, arrowIcon, background,
- foreground, defaultTextIconGap);
- }
-
/**
* Method which renders the text of the current menu item.
* <p>
diff --git a/jdk/src/share/classes/java/util/Currency.java b/jdk/src/share/classes/java/util/Currency.java
index 5305a3a38c..09d97f89fa 100644
--- a/jdk/src/share/classes/java/util/Currency.java
+++ b/jdk/src/share/classes/java/util/Currency.java
@@ -147,13 +147,33 @@ public final class Currency implements Serializable {
// - bits 0-4: final char for currency code for simple country, or ID of special case
// - special case IDs:
// - 0: country has no currency
- // - other: index into specialCasesList
+ // - other: index into sc* arrays + 1
+ // - scCutOverTimes: cut-over time in millis as returned by
+ // System.currentTimeMillis for special case countries that are changing
+ // currencies; Long.MAX_VALUE for countries that are not changing currencies
+ // - scOldCurrencies: old currencies for special case countries
+ // - scNewCurrencies: new currencies for special case countries that are
+ // changing currencies; null for others
+ // - scOldCurrenciesDFD: default fraction digits for old currencies
+ // - scNewCurrenciesDFD: default fraction digits for new currencies, 0 for
+ // countries that are not changing currencies
+ // - otherCurrencies: concatenation of all currency codes that are not the
+ // main currency of a simple country, separated by "-"
+ // - otherCurrenciesDFD: decimal format digits for currencies in otherCurrencies, same order
static int formatVersion;
static int dataVersion;
static int[] mainTable;
- static List<SpecialCaseEntry> specialCasesList;
- static List<OtherCurrencyEntry> otherCurrenciesList;
+ static long[] scCutOverTimes;
+ static String[] scOldCurrencies;
+ static String[] scNewCurrencies;
+ static int[] scOldCurrenciesDFD;
+ static int[] scNewCurrenciesDFD;
+ static int[] scOldCurrenciesNumericCode;
+ static int[] scNewCurrenciesNumericCode;
+ static String otherCurrencies;
+ static int[] otherCurrenciesDFD;
+ static int[] otherCurrenciesNumericCode;
// handy constants - must match definitions in GenerateCurrencyData
// magic number
@@ -188,7 +208,7 @@ public final class Currency implements Serializable {
private static final int NUMERIC_CODE_SHIFT = 10;
// Currency data format version
- private static final int VALID_FORMAT_VERSION = 3;
+ private static final int VALID_FORMAT_VERSION = 2;
static {
AccessController.doPrivileged(new PrivilegedAction<Void>() {
@@ -211,9 +231,17 @@ public final class Currency implements Serializable {
dataVersion = dis.readInt();
mainTable = readIntArray(dis, A_TO_Z * A_TO_Z);
int scCount = dis.readInt();
- specialCasesList = readSpecialCases(dis, scCount);
+ scCutOverTimes = readLongArray(dis, scCount);
+ scOldCurrencies = readStringArray(dis, scCount);
+ scNewCurrencies = readStringArray(dis, scCount);
+ scOldCurrenciesDFD = readIntArray(dis, scCount);
+ scNewCurrenciesDFD = readIntArray(dis, scCount);
+ scOldCurrenciesNumericCode = readIntArray(dis, scCount);
+ scNewCurrenciesNumericCode = readIntArray(dis, scCount);
int ocCount = dis.readInt();
- otherCurrenciesList = readOtherCurrencies(dis, ocCount);
+ otherCurrencies = dis.readUTF();
+ otherCurrenciesDFD = readIntArray(dis, ocCount);
+ otherCurrenciesNumericCode = readIntArray(dis, ocCount);
}
} catch (IOException e) {
throw new InternalError(e);
@@ -296,7 +324,6 @@ public final class Currency implements Serializable {
// Currency code not internally generated, need to verify first
// A currency code must have 3 characters and exist in the main table
// or in the list of other currencies.
- boolean found = false;
if (currencyCode.length() != 3) {
throw new IllegalArgumentException();
}
@@ -308,23 +335,17 @@ public final class Currency implements Serializable {
&& currencyCode.charAt(2) - 'A' == (tableEntry & SIMPLE_CASE_COUNTRY_FINAL_CHAR_MASK)) {
defaultFractionDigits = (tableEntry & SIMPLE_CASE_COUNTRY_DEFAULT_DIGITS_MASK) >> SIMPLE_CASE_COUNTRY_DEFAULT_DIGITS_SHIFT;
numericCode = (tableEntry & NUMERIC_CODE_MASK) >> NUMERIC_CODE_SHIFT;
- found = true;
- } else { //special case
- int[] fractionAndNumericCode = SpecialCaseEntry.findEntry(currencyCode);
- if (fractionAndNumericCode != null) {
- defaultFractionDigits = fractionAndNumericCode[0];
- numericCode = fractionAndNumericCode[1];
- found = true;
+ } else {
+ // Check for '-' separately so we don't get false hits in the table.
+ if (currencyCode.charAt(2) == '-') {
+ throw new IllegalArgumentException();
}
- }
-
- if (!found) {
- OtherCurrencyEntry ocEntry = OtherCurrencyEntry.findEntry(currencyCode);
- if (ocEntry == null) {
+ int index = otherCurrencies.indexOf(currencyCode);
+ if (index == -1) {
throw new IllegalArgumentException();
}
- defaultFractionDigits = ocEntry.fraction;
- numericCode = ocEntry.numericCode;
+ defaultFractionDigits = otherCurrenciesDFD[index / 4];
+ numericCode = otherCurrenciesNumericCode[index / 4];
}
}
@@ -384,17 +405,13 @@ public final class Currency implements Serializable {
if (tableEntry == COUNTRY_WITHOUT_CURRENCY_ENTRY) {
return null;
} else {
- int index = SpecialCaseEntry.toIndex(tableEntry);
- SpecialCaseEntry scEntry = specialCasesList.get(index);
- if (scEntry.cutOverTime == Long.MAX_VALUE
- || System.currentTimeMillis() < scEntry.cutOverTime) {
- return getInstance(scEntry.oldCurrency,
- scEntry.oldCurrencyFraction,
- scEntry.oldCurrencyNumericCode);
+ int index = (tableEntry & SPECIAL_CASE_COUNTRY_INDEX_MASK) - SPECIAL_CASE_COUNTRY_INDEX_DELTA;
+ if (scCutOverTimes[index] == Long.MAX_VALUE || System.currentTimeMillis() < scCutOverTimes[index]) {
+ return getInstance(scOldCurrencies[index], scOldCurrenciesDFD[index],
+ scOldCurrenciesNumericCode[index]);
} else {
- return getInstance(scEntry.newCurrency,
- scEntry.newCurrencyFraction,
- scEntry.newCurrencyNumericCode);
+ return getInstance(scNewCurrencies[index], scNewCurrenciesDFD[index],
+ scNewCurrenciesNumericCode[index]);
}
}
}
@@ -429,29 +446,14 @@ public final class Currency implements Serializable {
sb.append(c2);
sb.append(finalChar);
available.add(getInstance(sb.toString(), defaultFractionDigits, numericCode));
- } else if ((tableEntry & COUNTRY_TYPE_MASK) == SPECIAL_CASE_COUNTRY_MASK
- && tableEntry != INVALID_COUNTRY_ENTRY
- && tableEntry != COUNTRY_WITHOUT_CURRENCY_ENTRY) {
- int index = SpecialCaseEntry.toIndex(tableEntry);
- SpecialCaseEntry scEntry = specialCasesList.get(index);
-
- if (scEntry.cutOverTime == Long.MAX_VALUE
- || System.currentTimeMillis() < scEntry.cutOverTime) {
- available.add(getInstance(scEntry.oldCurrency,
- scEntry.oldCurrencyFraction,
- scEntry.oldCurrencyNumericCode));
- } else {
- available.add(getInstance(scEntry.newCurrency,
- scEntry.newCurrencyFraction,
- scEntry.newCurrencyNumericCode));
- }
}
}
}
// Now add other currencies
- for (OtherCurrencyEntry entry : otherCurrenciesList) {
- available.add(getInstance(entry.currencyCode));
+ StringTokenizer st = new StringTokenizer(otherCurrencies, "-");
+ while (st.hasMoreElements()) {
+ available.add(getInstance((String)st.nextElement()));
}
}
}
@@ -657,55 +659,22 @@ public final class Currency implements Serializable {
return ret;
}
- private static List<SpecialCaseEntry> readSpecialCases(DataInputStream dis,
- int count)
- throws IOException {
-
- List<SpecialCaseEntry> list = new ArrayList<>(count);
- long cutOverTime;
- String oldCurrency;
- String newCurrency;
- int oldCurrencyFraction;
- int newCurrencyFraction;
- int oldCurrencyNumericCode;
- int newCurrencyNumericCode;
-
+ private static long[] readLongArray(DataInputStream dis, int count) throws IOException {
+ long[] ret = new long[count];
for (int i = 0; i < count; i++) {
- cutOverTime = dis.readLong();
- oldCurrency = dis.readUTF();
- newCurrency = dis.readUTF();
- oldCurrencyFraction = dis.readInt();
- newCurrencyFraction = dis.readInt();
- oldCurrencyNumericCode = dis.readInt();
- newCurrencyNumericCode = dis.readInt();
- SpecialCaseEntry sc = new SpecialCaseEntry(cutOverTime,
- oldCurrency, newCurrency,
- oldCurrencyFraction, newCurrencyFraction,
- oldCurrencyNumericCode, newCurrencyNumericCode);
- list.add(sc);
+ ret[i] = dis.readLong();
}
- return list;
- }
-
- private static List<OtherCurrencyEntry> readOtherCurrencies(DataInputStream dis,
- int count)
- throws IOException {
- List<OtherCurrencyEntry> list = new ArrayList<>(count);
- String currencyCode;
- int fraction;
- int numericCode;
+ return ret;
+ }
+ private static String[] readStringArray(DataInputStream dis, int count) throws IOException {
+ String[] ret = new String[count];
for (int i = 0; i < count; i++) {
- currencyCode = dis.readUTF();
- fraction = dis.readInt();
- numericCode = dis.readInt();
- OtherCurrencyEntry oc = new OtherCurrencyEntry(currencyCode,
- fraction,
- numericCode);
- list.add(oc);
+ ret[i] = dis.readUTF();
}
- return list;
+
+ return ret;
}
/**
@@ -763,27 +732,21 @@ public final class Currency implements Serializable {
return;
}
- int index = SpecialCaseEntry.indexOf(code, fraction, numeric);
-
- /* if a country switches from simple case to special case or
- * one special case to other special case which is not present
- * in the sc arrays then insert the new entry in special case arrays
- */
- if (index == -1 && (ctry.charAt(0) != code.charAt(0)
- || ctry.charAt(1) != code.charAt(1))) {
-
- specialCasesList.add(new SpecialCaseEntry(code, fraction, numeric));
- index = specialCasesList.size() - 1;
+ int index;
+ for (index = 0; index < scOldCurrencies.length; index++) {
+ if (scOldCurrencies[index].equals(code)) {
+ break;
+ }
}
- if (index == -1) {
+ if (index == scOldCurrencies.length) {
// simple case
- entry |= (fraction << SIMPLE_CASE_COUNTRY_DEFAULT_DIGITS_SHIFT)
- | (code.charAt(2) - 'A');
+ entry |= (fraction << SIMPLE_CASE_COUNTRY_DEFAULT_DIGITS_SHIFT) |
+ (code.charAt(2) - 'A');
} else {
// special case
- entry = SPECIAL_CASE_COUNTRY_MASK
- | (index + SPECIAL_CASE_COUNTRY_INDEX_DELTA);
+ entry |= SPECIAL_CASE_COUNTRY_MASK |
+ (index + SPECIAL_CASE_COUNTRY_INDEX_DELTA);
}
setMainTableEntry(ctry.charAt(0), ctry.charAt(1), entry);
}
@@ -817,126 +780,4 @@ public final class Currency implements Serializable {
}
}
}
-
- /* Used to represent a special case currency entry
- * - cutOverTime: cut-over time in millis as returned by
- * System.currentTimeMillis for special case countries that are changing
- * currencies; Long.MAX_VALUE for countries that are not changing currencies
- * - oldCurrency: old currencies for special case countries
- * - newCurrency: new currencies for special case countries that are
- * changing currencies; null for others
- * - oldCurrencyFraction: default fraction digits for old currencies
- * - newCurrencyFraction: default fraction digits for new currencies, 0 for
- * countries that are not changing currencies
- * - oldCurrencyNumericCode: numeric code for old currencies
- * - newCurrencyNumericCode: numeric code for new currencies, 0 for countries
- * that are not changing currencies
- */
- private static class SpecialCaseEntry {
-
- final private long cutOverTime;
- final private String oldCurrency;
- final private String newCurrency;
- final private int oldCurrencyFraction;
- final private int newCurrencyFraction;
- final private int oldCurrencyNumericCode;
- final private int newCurrencyNumericCode;
-
- private SpecialCaseEntry(long cutOverTime, String oldCurrency, String newCurrency,
- int oldCurrencyFraction, int newCurrencyFraction,
- int oldCurrencyNumericCode, int newCurrencyNumericCode) {
- this.cutOverTime = cutOverTime;
- this.oldCurrency = oldCurrency;
- this.newCurrency = newCurrency;
- this.oldCurrencyFraction = oldCurrencyFraction;
- this.newCurrencyFraction = newCurrencyFraction;
- this.oldCurrencyNumericCode = oldCurrencyNumericCode;
- this.newCurrencyNumericCode = newCurrencyNumericCode;
- }
-
- private SpecialCaseEntry(String currencyCode, int fraction,
- int numericCode) {
- this(Long.MAX_VALUE, currencyCode, "", fraction, 0, numericCode, 0);
- }
-
- //get the index of the special case entry
- private static int indexOf(String code, int fraction, int numeric) {
- int size = specialCasesList.size();
- for (int index = 0; index < size; index++) {
- SpecialCaseEntry scEntry = specialCasesList.get(index);
- if (scEntry.oldCurrency.equals(code)
- && scEntry.oldCurrencyFraction == fraction
- && scEntry.oldCurrencyNumericCode == numeric
- && scEntry.cutOverTime == Long.MAX_VALUE) {
- return index;
- }
- }
- return -1;
- }
-
- // get the fraction and numericCode of the sc currencycode
- private static int[] findEntry(String code) {
- int[] fractionAndNumericCode = null;
- int size = specialCasesList.size();
- for (int index = 0; index < size; index++) {
- SpecialCaseEntry scEntry = specialCasesList.get(index);
- if (scEntry.oldCurrency.equals(code) && (scEntry.cutOverTime == Long.MAX_VALUE
- || System.currentTimeMillis() < scEntry.cutOverTime)) {
- //consider only when there is no new currency or cutover time is not passed
- fractionAndNumericCode = new int[2];
- fractionAndNumericCode[0] = scEntry.oldCurrencyFraction;
- fractionAndNumericCode[1] = scEntry.oldCurrencyNumericCode;
- break;
- } else if (scEntry.newCurrency.equals(code)
- && System.currentTimeMillis() >= scEntry.cutOverTime) {
- //consider only if the cutover time is passed
- fractionAndNumericCode = new int[2];
- fractionAndNumericCode[0] = scEntry.newCurrencyFraction;
- fractionAndNumericCode[1] = scEntry.newCurrencyNumericCode;
- break;
- }
- }
- return fractionAndNumericCode;
- }
-
- // convert the special case entry to sc arrays index
- private static int toIndex(int tableEntry) {
- return (tableEntry & SPECIAL_CASE_COUNTRY_INDEX_MASK) - SPECIAL_CASE_COUNTRY_INDEX_DELTA;
- }
-
- }
-
- /* Used to represent Other currencies
- * - currencyCode: currency codes that are not the main currency
- * of a simple country
- * - otherCurrenciesDFD: decimal format digits for other currencies
- * - otherCurrenciesNumericCode: numeric code for other currencies
- */
- private static class OtherCurrencyEntry {
-
- final private String currencyCode;
- final private int fraction;
- final private int numericCode;
-
- private OtherCurrencyEntry(String currencyCode, int fraction,
- int numericCode) {
- this.currencyCode = currencyCode;
- this.fraction = fraction;
- this.numericCode = numericCode;
- }
-
- //get the instance of the other currency code
- private static OtherCurrencyEntry findEntry(String code) {
- int size = otherCurrenciesList.size();
- for (int index = 0; index < size; index++) {
- OtherCurrencyEntry ocEntry = otherCurrenciesList.get(index);
- if (ocEntry.currencyCode.equalsIgnoreCase(code)) {
- return ocEntry;
- }
- }
- return null;
- }
-
- }
-
}
diff --git a/jdk/src/share/classes/java/util/CurrencyData.properties b/jdk/src/share/classes/java/util/CurrencyData.properties
index 7d1b74b5d1..79becc3e6d 100644
--- a/jdk/src/share/classes/java/util/CurrencyData.properties
+++ b/jdk/src/share/classes/java/util/CurrencyData.properties
@@ -26,13 +26,12 @@
# Version of the currency data format.
# 1: initial
# 2: Change in minor unit (allowing 4-9 digits)
-# 3: Change in the order of special case and other currency entries
-formatVersion=3
+formatVersion=2
# Version of the currency code information in this class.
# It is a serial number that accompanies with each amendment.
-dataVersion=180
+dataVersion=179
# List of all valid ISO 4217 currency codes.
# To ensure compatibility, do not remove codes.
@@ -147,7 +146,7 @@ IO=USD
# BRUNEI DARUSSALAM
BN=BND
# BULGARIA
-BG=BGN;2025-12-31-22-00-00;EUR
+BG=BGN
# BURKINA FASO
BF=XOF
# BURUNDI
diff --git a/jdk/src/share/classes/javax/swing/plaf/basic/BasicMenuItemUI.java b/jdk/src/share/classes/javax/swing/plaf/basic/BasicMenuItemUI.java
index 0467cf11d4..54994b61e3 100644
--- a/jdk/src/share/classes/javax/swing/plaf/basic/BasicMenuItemUI.java
+++ b/jdk/src/share/classes/javax/swing/plaf/basic/BasicMenuItemUI.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 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
@@ -25,52 +25,17 @@
package javax.swing.plaf.basic;
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Dimension;
-import java.awt.Font;
-import java.awt.FontMetrics;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.Point;
-import java.awt.Rectangle;
-import java.awt.event.ActionEvent;
-import java.awt.event.InputEvent;
-import java.awt.event.MouseEvent;
+import java.awt.*;
+import java.awt.event.*;
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
-import javax.swing.ButtonModel;
-import javax.swing.Icon;
-import javax.swing.InputMap;
-import javax.swing.JCheckBoxMenuItem;
-import javax.swing.JComponent;
-import javax.swing.JMenu;
-import javax.swing.JMenuItem;
-import javax.swing.JRadioButtonMenuItem;
-import javax.swing.KeyStroke;
-import javax.swing.LookAndFeel;
-import javax.swing.MenuElement;
-import javax.swing.MenuSelectionManager;
-import javax.swing.SwingUtilities;
-import javax.swing.UIManager;
-import javax.swing.event.MenuDragMouseEvent;
-import javax.swing.event.MenuDragMouseListener;
-import javax.swing.event.MenuKeyListener;
-
-import javax.swing.event.MouseInputListener;
-import javax.swing.plaf.ComponentInputMapUIResource;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.MenuItemUI;
-import javax.swing.plaf.UIResource;
+import javax.swing.*;
+import javax.swing.event.*;
+import javax.swing.plaf.*;
import javax.swing.text.View;
-import com.sun.java.swing.SwingUtilities3;
-import sun.swing.MenuItemCheckIconFactory;
-import sun.swing.MenuItemLayoutHelper;
-import sun.swing.SwingUtilities2;
-import sun.swing.UIAction;
-
+import sun.swing.*;
/**
* BasicMenuItem implementation
@@ -596,21 +561,84 @@ public class BasicMenuItemUI extends MenuItemUI
private void paintIcon(Graphics g, MenuItemLayoutHelper lh,
MenuItemLayoutHelper.LayoutResult lr, Color holdc) {
- SwingUtilities3.paintIcon(g, lh, lr, holdc);
+ if (lh.getIcon() != null) {
+ Icon icon;
+ ButtonModel model = lh.getMenuItem().getModel();
+ if (!model.isEnabled()) {
+ icon = lh.getMenuItem().getDisabledIcon();
+ } else if (model.isPressed() && model.isArmed()) {
+ icon = lh.getMenuItem().getPressedIcon();
+ if (icon == null) {
+ // Use default icon
+ icon = lh.getMenuItem().getIcon();
+ }
+ } else {
+ icon = lh.getMenuItem().getIcon();
+ }
+
+ if (icon != null) {
+ icon.paintIcon(lh.getMenuItem(), g, lr.getIconRect().x,
+ lr.getIconRect().y);
+ g.setColor(holdc);
+ }
+ }
}
private void paintCheckIcon(Graphics g, MenuItemLayoutHelper lh,
MenuItemLayoutHelper.LayoutResult lr,
Color holdc, Color foreground) {
- SwingUtilities3.paintCheckIcon(g, lh, lr, holdc, foreground);
+ if (lh.getCheckIcon() != null) {
+ ButtonModel model = lh.getMenuItem().getModel();
+ if (model.isArmed() || (lh.getMenuItem() instanceof JMenu
+ && model.isSelected())) {
+ g.setColor(foreground);
+ } else {
+ g.setColor(holdc);
+ }
+ if (lh.useCheckAndArrow()) {
+ lh.getCheckIcon().paintIcon(lh.getMenuItem(), g,
+ lr.getCheckRect().x, lr.getCheckRect().y);
+ }
+ g.setColor(holdc);
+ }
}
private void paintAccText(Graphics g, MenuItemLayoutHelper lh,
MenuItemLayoutHelper.LayoutResult lr) {
- SwingUtilities3.paintAccText(g, lh, lr,
- disabledForeground,
- acceleratorSelectionForeground,
- acceleratorForeground);
+ if (!lh.getAccText().equals("")) {
+ ButtonModel model = lh.getMenuItem().getModel();
+ g.setFont(lh.getAccFontMetrics().getFont());
+ if (!model.isEnabled()) {
+ // *** paint the accText disabled
+ if (disabledForeground != null) {
+ g.setColor(disabledForeground);
+ SwingUtilities2.drawString(lh.getMenuItem(), g,
+ lh.getAccText(), lr.getAccRect().x,
+ lr.getAccRect().y + lh.getAccFontMetrics().getAscent());
+ } else {
+ g.setColor(lh.getMenuItem().getBackground().brighter());
+ SwingUtilities2.drawString(lh.getMenuItem(), g,
+ lh.getAccText(), lr.getAccRect().x,
+ lr.getAccRect().y + lh.getAccFontMetrics().getAscent());
+ g.setColor(lh.getMenuItem().getBackground().darker());
+ SwingUtilities2.drawString(lh.getMenuItem(), g,
+ lh.getAccText(), lr.getAccRect().x - 1,
+ lr.getAccRect().y + lh.getFontMetrics().getAscent() - 1);
+ }
+ } else {
+ // *** paint the accText normally
+ if (model.isArmed()
+ || (lh.getMenuItem() instanceof JMenu
+ && model.isSelected())) {
+ g.setColor(acceleratorSelectionForeground);
+ } else {
+ g.setColor(acceleratorForeground);
+ }
+ SwingUtilities2.drawString(lh.getMenuItem(), g, lh.getAccText(),
+ lr.getAccRect().x, lr.getAccRect().y +
+ lh.getAccFontMetrics().getAscent());
+ }
+ }
}
private void paintText(Graphics g, MenuItemLayoutHelper lh,
@@ -629,11 +657,26 @@ public class BasicMenuItemUI extends MenuItemUI
private void paintArrowIcon(Graphics g, MenuItemLayoutHelper lh,
MenuItemLayoutHelper.LayoutResult lr,
Color foreground) {
- SwingUtilities3.paintArrowIcon(g, lh, lr, foreground);
+ if (lh.getArrowIcon() != null) {
+ ButtonModel model = lh.getMenuItem().getModel();
+ if (model.isArmed() || (lh.getMenuItem() instanceof JMenu
+ && model.isSelected())) {
+ g.setColor(foreground);
+ }
+ if (lh.useCheckAndArrow()) {
+ lh.getArrowIcon().paintIcon(lh.getMenuItem(), g,
+ lr.getArrowRect().x, lr.getArrowRect().y);
+ }
+ }
}
private void applyInsets(Rectangle rect, Insets insets) {
- SwingUtilities3.applyInsets(rect, insets);
+ if(insets != null) {
+ rect.x += insets.left;
+ rect.y += insets.top;
+ rect.width -= (insets.right + rect.x);
+ rect.height -= (insets.bottom + rect.y);
+ }
}
/**
diff --git a/jdk/src/share/classes/sun/security/util/DerValue.java b/jdk/src/share/classes/sun/security/util/DerValue.java
index 2dd262ba99..b7d1714769 100644
--- a/jdk/src/share/classes/sun/security/util/DerValue.java
+++ b/jdk/src/share/classes/sun/security/util/DerValue.java
@@ -822,22 +822,6 @@ public class DerValue {
doEquals(other, this);
}
- /**
- * Checks that the BMPString does not contain any surrogate characters,
- * which are outside the Basic Multilingual Plane.
- *
- * @throws IOException if illegal characters are detected
- */
- public void validateBMPString() throws IOException {
- String bmpString = getBMPString();
- for (int i = 0; i < bmpString.length(); i++) {
- if (Character.isSurrogate(bmpString.charAt(i))) {
- throw new IOException(
- "Illegal character in BMPString, index: " + i);
- }
- }
- }
-
/**
* Helper for public method equals()
*/
diff --git a/jdk/src/share/classes/sun/security/validator/EntrustTLSPolicy.java b/jdk/src/share/classes/sun/security/validator/EntrustTLSPolicy.java
index 51b6450072..7a67199a1a 100644
--- a/jdk/src/share/classes/sun/security/validator/EntrustTLSPolicy.java
+++ b/jdk/src/share/classes/sun/security/validator/EntrustTLSPolicy.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2024, 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
@@ -75,7 +75,19 @@ final class EntrustTLSPolicy {
// OU=(c) 1999 Entrust.net Limited,
// OU=www.entrust.net/CPS_2048 incorp. by ref. (limits liab.),
// O=Entrust.net
- "6DC47172E01CBCB0BF62580D895FE2B8AC9AD4F873801E0C10B9C837D21EB177"
+ "6DC47172E01CBCB0BF62580D895FE2B8AC9AD4F873801E0C10B9C837D21EB177",
+ // cacerts alias: affirmtrustcommercialca
+ // DN: CN=AffirmTrust Commercial, O=AffirmTrust, C=US
+ "0376AB1D54C5F9803CE4B2E201A0EE7EEF7B57B636E8A93C9B8D4860C96F5FA7",
+ // cacerts alias: affirmtrustnetworkingca
+ // DN: CN=AffirmTrust Networking, O=AffirmTrust, C=US
+ "0A81EC5A929777F145904AF38D5D509F66B5E2C58FCDB531058B0E17F3F0B41B",
+ // cacerts alias: affirmtrustpremiumca
+ // DN: CN=AffirmTrust Premium, O=AffirmTrust, C=US
+ "70A73F7F376B60074248904534B11482D5BF0E698ECC498DF52577EBF2E93B9A",
+ // cacerts alias: affirmtrustpremiumeccca
+ // DN: CN=AffirmTrust Premium ECC, O=AffirmTrust, C=US
+ "BD71FDF6DA97E4CF62D1647ADD2581B07D79ADF8397EB4ECBA9C5E8488821423"
)));
// Any TLS Server certificate that is anchored by one of the Entrust
diff --git a/jdk/src/share/classes/sun/security/x509/AVA.java b/jdk/src/share/classes/sun/security/x509/AVA.java
index f896b8d6e8..8665745c35 100644
--- a/jdk/src/share/classes/sun/security/x509/AVA.java
+++ b/jdk/src/share/classes/sun/security/x509/AVA.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1996, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,14 +30,9 @@ import java.io.IOException;
import java.io.OutputStream;
import java.io.Reader;
import java.security.AccessController;
-import java.nio.charset.Charset;
import java.text.Normalizer;
import java.util.*;
-import static java.nio.charset.StandardCharsets.ISO_8859_1;
-import static java.nio.charset.StandardCharsets.UTF_8;
-import static java.nio.charset.StandardCharsets.UTF_16BE;
-
import sun.security.action.GetBooleanAction;
import sun.security.util.*;
import sun.security.pkcs.PKCS9Attribute;
@@ -611,10 +606,6 @@ public class AVA implements DerEncoder {
throw new IOException("AVA, extra bytes = "
+ derval.data.available());
}
-
- if (value.tag == DerValue.tag_BMPString) {
- value.validateBMPString();
- }
}
AVA(DerInputStream in) throws IOException {
@@ -762,7 +753,7 @@ public class AVA implements DerEncoder {
*/
String valStr = null;
try {
- valStr = new String(value.getDataBytes(), getCharset(value, false));
+ valStr = new String(value.getDataBytes(), "UTF8");
} catch (IOException ie) {
throw new IllegalArgumentException("DER Value conversion");
}
@@ -915,7 +906,7 @@ public class AVA implements DerEncoder {
*/
String valStr = null;
try {
- valStr = new String(value.getDataBytes(), getCharset(value, true));
+ valStr = new String(value.getDataBytes(), "UTF8");
} catch (IOException ie) {
throw new IllegalArgumentException("DER Value conversion");
}
@@ -1035,46 +1026,6 @@ public class AVA implements DerEncoder {
}
}
- /*
- * Returns the charset that should be used to decode each DN string type.
- *
- * This method ensures that multi-byte (UTF8String and BMPString) types
- * are decoded using the correct charset and the String forms represent
- * the correct characters. For 8-bit ASCII-based types (PrintableString
- * and IA5String), we return ISO_8859_1 rather than ASCII, so that the
- * complete range of characters can be represented, as many certificates
- * do not comply with the Internationalized Domain Name ACE format.
- *
- * NOTE: this method only supports DirectoryStrings of the types returned
- * by isDerString().
- */
- private static Charset getCharset(DerValue value, boolean canonical) {
- if (canonical) {
- switch (value.tag) {
- case DerValue.tag_PrintableString:
- return ISO_8859_1;
- case DerValue.tag_UTF8String:
- return UTF_8;
- default:
- throw new Error("unexpected tag: " + value.tag);
- }
- }
-
- switch (value.tag) {
- case DerValue.tag_PrintableString:
- case DerValue.tag_T61String:
- case DerValue.tag_IA5String:
- case DerValue.tag_GeneralString:
- return ISO_8859_1;
- case DerValue.tag_BMPString:
- return UTF_16BE;
- case DerValue.tag_UTF8String:
- return UTF_8;
- default:
- throw new Error("unexpected tag: " + value.tag);
- }
- }
-
boolean hasRFC2253Keyword() {
return AVAKeyword.hasKeyword(oid, RFC2253);
}
diff --git a/jdk/src/share/native/common/check_code.c b/jdk/src/share/native/common/check_code.c
index 0889c57f49..799b8c654c 100644
--- a/jdk/src/share/native/common/check_code.c
+++ b/jdk/src/share/native/common/check_code.c
@@ -396,8 +396,7 @@ static jboolean is_superclass(context_type *, fullinfo_type);
static void initialize_exception_table(context_type *);
static int instruction_length(unsigned char *iptr, unsigned char *end);
-static jboolean isLegalOffset(context_type *, int bci, int offset);
-static jboolean isLegalTarget(context_type *, int target);
+static jboolean isLegalTarget(context_type *, int offset);
static void verify_constant_pool_type(context_type *, int, unsigned);
static void initialize_dataflow(context_type *);
@@ -1162,9 +1161,9 @@ verify_opcode_operands(context_type *context, unsigned int inumber, int offset)
case JVM_OPC_goto: {
/* Set the ->operand to be the instruction number of the target. */
int jump = (((signed char)(code[offset+1])) << 8) + code[offset+2];
- if (!isLegalOffset(context, offset, jump))
- CCerror(context, "Illegal target of jump or branch");
int target = offset + jump;
+ if (!isLegalTarget(context, target))
+ CCerror(context, "Illegal target of jump or branch");
this_idata->operand.i = code_data[target];
break;
}
@@ -1178,9 +1177,9 @@ verify_opcode_operands(context_type *context, unsigned int inumber, int offset)
int jump = (((signed char)(code[offset+1])) << 24) +
(code[offset+2] << 16) + (code[offset+3] << 8) +
(code[offset + 4]);
- if (!isLegalOffset(context, offset, jump))
- CCerror(context, "Illegal target of jump or branch");
int target = offset + jump;
+ if (!isLegalTarget(context, target))
+ CCerror(context, "Illegal target of jump or branch");
this_idata->operand.i = code_data[target];
break;
}
@@ -1219,16 +1218,13 @@ verify_opcode_operands(context_type *context, unsigned int inumber, int offset)
}
}
saved_operand = NEW(int, keys + 2);
- int jump = _ck_ntohl(lpc[0]);
- if (!isLegalOffset(context, offset, jump))
+ if (!isLegalTarget(context, offset + _ck_ntohl(lpc[0])))
CCerror(context, "Illegal default target in switch");
- int target = offset + jump;
- saved_operand[keys + 1] = code_data[target];
+ saved_operand[keys + 1] = code_data[offset + _ck_ntohl(lpc[0])];
for (k = keys, lptr = &lpc[3]; --k >= 0; lptr += delta) {
- jump = _ck_ntohl(lptr[0]);
- if (!isLegalOffset(context, offset, jump))
+ int target = offset + _ck_ntohl(lptr[0]);
+ if (!isLegalTarget(context, target))
CCerror(context, "Illegal branch in tableswitch");
- target = offset + jump;
saved_operand[k + 1] = code_data[target];
}
saved_operand[0] = keys + 1; /* number of successors */
@@ -1750,24 +1746,11 @@ static int instruction_length(unsigned char *iptr, unsigned char *end)
/* Given the target of a branch, make sure that it's a legal target. */
static jboolean
-isLegalTarget(context_type *context, int target)
-{
- int code_length = context->code_length;
- int *code_data = context->code_data;
- return (target >= 0 && target < code_length && code_data[target] >= 0);
-}
-
-/* Given a bci and offset, make sure the offset is valid and the target is legal */
-static jboolean
-isLegalOffset(context_type *context, int bci, int offset)
+isLegalTarget(context_type *context, int offset)
{
int code_length = context->code_length;
int *code_data = context->code_data;
- int max_offset = 65535; // JVMS 4.11
- int min_offset = -65535;
- if (offset < min_offset || offset > max_offset) return JNI_FALSE;
- int target = bci + offset;
- return (target >= 0 && target < code_length && code_data[target] >= 0);
+ return (offset >= 0 && offset < code_length && code_data[offset] >= 0);
}
diff --git a/jdk/src/solaris/native/java/net/Inet4AddressImpl.c b/jdk/src/solaris/native/java/net/Inet4AddressImpl.c
index 8b2e3cdce9..e30851df57 100644
--- a/jdk/src/solaris/native/java/net/Inet4AddressImpl.c
+++ b/jdk/src/solaris/native/java/net/Inet4AddressImpl.c
@@ -332,33 +332,37 @@ Java_java_net_Inet4AddressImpl_getHostByAddr(JNIEnv *env, jobject this,
*/
JNIEXPORT jstring JNICALL
Java_java_net_Inet4AddressImpl_getLocalHostName(JNIEnv *env, jobject this) {
- char hostname[NI_MAXHOST + 1];
+ char hostname[NI_MAXHOST+1];
hostname[0] = '\0';
if (JVM_GetHostName(hostname, sizeof(hostname))) {
+ /* Something went wrong, maybe networking is not setup? */
strcpy(hostname, "localhost");
} else {
-#if defined(__solaris__)
- // try to resolve hostname via nameservice
- // if it is known but getnameinfo fails, hostname will still be the
- // value from gethostname
struct addrinfo hints, *res;
+ int error;
- // make sure string is null-terminated
hostname[NI_MAXHOST] = '\0';
memset(&hints, 0, sizeof(hints));
hints.ai_flags = AI_CANONNAME;
hints.ai_family = AF_INET;
- if (getaddrinfo(hostname, NULL, &hints, &res) == 0) {
- getnameinfo(res->ai_addr, res->ai_addrlen, hostname, NI_MAXHOST,
- NULL, 0, NI_NAMEREQD);
+ error = getaddrinfo(hostname, NULL, &hints, &res);
+
+ if (error == 0) {/* host is known to name service */
+ getnameinfo(res->ai_addr,
+ res->ai_addrlen,
+ hostname,
+ NI_MAXHOST,
+ NULL,
+ 0,
+ NI_NAMEREQD);
+
+ /* if getnameinfo fails hostname is still the value
+ from gethostname */
+
freeaddrinfo(res);
}
-#else
- // make sure string is null-terminated
- hostname[NI_MAXHOST] = '\0';
-#endif
}
return (*env)->NewStringUTF(env, hostname);
}
diff --git a/jdk/src/solaris/native/java/net/bsd_close.c b/jdk/src/solaris/native/java/net/bsd_close.c
index a6050e1f9a..89a20707c4 100644
--- a/jdk/src/solaris/native/java/net/bsd_close.c
+++ b/jdk/src/solaris/native/java/net/bsd_close.c
@@ -39,7 +39,6 @@
#include <unistd.h>
#include <errno.h>
#include <sys/poll.h>
-#include "jvm.h"
/*
* Stack allocated by thread when doing blocking operation
@@ -348,55 +347,55 @@ int NET_SocketClose(int fd) {
/************** Basic I/O operations here ***************/
/*
- * Macro to perform a blocking IO operation.
- * If interrupted by signal (other than our wakeup signal), and if RETRY is true,
- * then restarts automatically
+ * Macro to perform a blocking IO operation. Restarts
+ * automatically if interrupted by signal (other than
+ * our wakeup signal)
*/
-#define BLOCKING_IO_RETURN_INT(FD, FUNC, RETRY) { \
- int ret; \
- threadEntry_t self; \
- fdEntry_t *fdEntry = getFdEntry(FD); \
- if (fdEntry == NULL) { \
- errno = EBADF; \
- return -1; \
- } \
- do { \
- startOp(fdEntry, &self); \
- ret = FUNC; \
- endOp(fdEntry, &self); \
- } while ((RETRY) && ret == -1 && errno == EINTR); \
- return ret; \
+#define BLOCKING_IO_RETURN_INT(FD, FUNC) { \
+ int ret; \
+ threadEntry_t self; \
+ fdEntry_t *fdEntry = getFdEntry(FD); \
+ if (fdEntry == NULL) { \
+ errno = EBADF; \
+ return -1; \
+ } \
+ do { \
+ startOp(fdEntry, &self); \
+ ret = FUNC; \
+ endOp(fdEntry, &self); \
+ } while (ret == -1 && errno == EINTR); \
+ return ret; \
}
int NET_Read(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0) );
}
int NET_NonBlockingRead(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, MSG_DONTWAIT), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, MSG_DONTWAIT));
}
int NET_ReadV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, readv(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, readv(s, vector, count) );
}
int NET_RecvFrom(int s, void *buf, int len, unsigned int flags,
struct sockaddr *from, int *fromlen) {
/* casting int *fromlen -> socklen_t* Both are ints */
- BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, (socklen_t *)fromlen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, (socklen_t *)fromlen) );
}
int NET_Send(int s, void *msg, int len, unsigned int flags) {
- BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags) );
}
int NET_WriteV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, writev(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, writev(s, vector, count) );
}
int NET_SendTo(int s, const void *msg, int len, unsigned int
flags, const struct sockaddr *to, int tolen) {
- BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen) );
}
int NET_Accept(int s, struct sockaddr *addr, int *addrlen) {
@@ -404,22 +403,22 @@ int NET_Accept(int s, struct sockaddr *addr, int *addrlen) {
int error = accept(s, addr, &len);
if (error != -1)
*addrlen = (int)len;
- BLOCKING_IO_RETURN_INT( s, error, JNI_FALSE );
+ BLOCKING_IO_RETURN_INT( s, error );
}
int NET_Connect(int s, struct sockaddr *addr, int addrlen) {
- BLOCKING_IO_RETURN_INT( s, connect(s, addr, addrlen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, connect(s, addr, addrlen) );
}
#ifndef USE_SELECT
int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
- BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout), JNI_FALSE );
+ BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout) );
}
#else
int NET_Select(int s, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds, struct timeval *timeout) {
BLOCKING_IO_RETURN_INT( s-1,
- select(s, readfds, writefds, exceptfds, timeout), JNI_TRUE );
+ select(s, readfds, writefds, exceptfds, timeout) );
}
#endif
diff --git a/jdk/src/solaris/native/java/net/linux_close.c b/jdk/src/solaris/native/java/net/linux_close.c
index c7a148c746..f4c53a0d01 100644
--- a/jdk/src/solaris/native/java/net/linux_close.c
+++ b/jdk/src/solaris/native/java/net/linux_close.c
@@ -37,7 +37,6 @@
#include <unistd.h>
#include <errno.h>
#include <sys/poll.h>
-#include "jvm.h"
/*
* Stack allocated by thread when doing blocking operation
@@ -344,77 +343,77 @@ int NET_SocketClose(int fd) {
/************** Basic I/O operations here ***************/
/*
- * Macro to perform a blocking IO operation.
- * If interrupted by signal (other than our wakeup signal), and if RETRY is true,
- * then restarts automatically
+ * Macro to perform a blocking IO operation. Restarts
+ * automatically if interrupted by signal (other than
+ * our wakeup signal)
*/
-#define BLOCKING_IO_RETURN_INT(FD, FUNC, RETRY) { \
- int ret; \
- threadEntry_t self; \
- fdEntry_t *fdEntry = getFdEntry(FD); \
- if (fdEntry == NULL) { \
- errno = EBADF; \
- return -1; \
- } \
- do { \
- startOp(fdEntry, &self); \
- ret = FUNC; \
- endOp(fdEntry, &self); \
- } while ((RETRY) && ret == -1 && errno == EINTR); \
- return ret; \
+#define BLOCKING_IO_RETURN_INT(FD, FUNC) { \
+ int ret; \
+ threadEntry_t self; \
+ fdEntry_t *fdEntry = getFdEntry(FD); \
+ if (fdEntry == NULL) { \
+ errno = EBADF; \
+ return -1; \
+ } \
+ do { \
+ startOp(fdEntry, &self); \
+ ret = FUNC; \
+ endOp(fdEntry, &self); \
+ } while (ret == -1 && errno == EINTR); \
+ return ret; \
}
int NET_Read(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, 0) );
}
int NET_NonBlockingRead(int s, void* buf, size_t len) {
- BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, MSG_DONTWAIT), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recv(s, buf, len, MSG_DONTWAIT) );
}
int NET_ReadV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, readv(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, readv(s, vector, count) );
}
int NET_RecvFrom(int s, void *buf, int len, unsigned int flags,
struct sockaddr *from, int *fromlen) {
socklen_t socklen = *fromlen;
- BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, &socklen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, recvfrom(s, buf, len, flags, from, &socklen) );
*fromlen = socklen;
}
int NET_Send(int s, void *msg, int len, unsigned int flags) {
- BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, send(s, msg, len, flags) );
}
int NET_WriteV(int s, const struct iovec * vector, int count) {
- BLOCKING_IO_RETURN_INT( s, writev(s, vector, count), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, writev(s, vector, count) );
}
int NET_SendTo(int s, const void *msg, int len, unsigned int
flags, const struct sockaddr *to, int tolen) {
- BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, sendto(s, msg, len, flags, to, tolen) );
}
int NET_Accept(int s, struct sockaddr *addr, int *addrlen) {
socklen_t socklen = *addrlen;
- BLOCKING_IO_RETURN_INT( s, accept(s, addr, &socklen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, accept(s, addr, &socklen) );
*addrlen = socklen;
}
int NET_Connect(int s, struct sockaddr *addr, int addrlen) {
- BLOCKING_IO_RETURN_INT( s, connect(s, addr, addrlen), JNI_TRUE );
+ BLOCKING_IO_RETURN_INT( s, connect(s, addr, addrlen) );
}
#ifndef USE_SELECT
int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
- BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout), JNI_FALSE );
+ BLOCKING_IO_RETURN_INT( ufds[0].fd, poll(ufds, nfds, timeout) );
}
#else
int NET_Select(int s, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds, struct timeval *timeout) {
BLOCKING_IO_RETURN_INT( s-1,
- select(s, readfds, writefds, exceptfds, timeout), JNI_TRUE );
+ select(s, readfds, writefds, exceptfds, timeout) );
}
#endif
diff --git a/jdk/src/windows/native/java/lang/java_props_md.c b/jdk/src/windows/native/java/lang/java_props_md.c
index 912c6fba0b..4768b06076 100644
--- a/jdk/src/windows/native/java/lang/java_props_md.c
+++ b/jdk/src/windows/native/java/lang/java_props_md.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1998, 2024, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2018, 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
@@ -480,8 +480,6 @@ GetJavaProperties(JNIEnv* env)
* where (buildNumber > 17762)
* Windows Server 2022 10 0 (!VER_NT_WORKSTATION)
* where (buildNumber > 20347)
- * Windows Server 2025 10 0 (!VER_NT_WORKSTATION)
- * where (buildNumber > 26039)
*
* This mapping will presumably be augmented as new Windows
* versions are released.
@@ -565,10 +563,7 @@ GetJavaProperties(JNIEnv* env)
case 0:
/* Windows server 2019 GA 10/2018 build number is 17763 */
/* Windows server 2022 build number is 20348 */
- /* Windows server 2025 Preview build is 26040 */
- if (buildNumber > 26039) {
- sprops.os_name = "Windows Server 2025";
- } else if (buildNumber > 20347) {
+ if (buildNumber > 20347) {
sprops.os_name = "Windows Server 2022";
} else if (buildNumber > 17676) {
sprops.os_name = "Windows Server 2019";
diff --git a/jdk/src/windows/native/sun/java2d/d3d/D3DBadHardware.h b/jdk/src/windows/native/sun/java2d/d3d/D3DBadHardware.h
index 78164472aa..83aedad8f7 100644
--- a/jdk/src/windows/native/sun/java2d/d3d/D3DBadHardware.h
+++ b/jdk/src/windows/native/sun/java2d/d3d/D3DBadHardware.h
@@ -54,9 +54,6 @@ static const ADAPTER_INFO badHardware[] = {
// All Intel Chips.
{ 0x8086, ALL_DEVICEIDS, NO_VERSION, OS_ALL },
- // Microsoft Basic Render Driver (as maybe used in VMs such as VirtualBox)
- { 0x1414, 0x008c, NO_VERSION, OS_ALL },
-
// ATI Mobility Radeon X1600, X1400, X1450, X1300, X1350
// Reason: workaround for 6613066, 6687166
// X1300 (four sub ids)
diff --git a/jdk/test/TEST.ROOT b/jdk/test/TEST.ROOT
index b6aa2e693a..b2d2ba1bcc 100644
--- a/jdk/test/TEST.ROOT
+++ b/jdk/test/TEST.ROOT
@@ -10,11 +10,9 @@
# randomness tests.
#
# A "headful" test requires a graphical environment to meaningfully
-# run. Tests that are not headful are "headless".
-# A test flagged with key "printer" requires a printer to succeed, else
-# throws a PrinterException or the like.
+# run. Tests that are not headful are "headless."
-keys=2d dnd headful i18n intermittent printer randomness jfr
+keys=2d dnd i18n intermittent randomness headful jfr
# Tests that must run in othervm mode
othervm.dirs=java/awt java/beans java/rmi javax/accessibility javax/imageio javax/sound javax/print javax/management com/sun/awt sun/awt sun/java2d sun/pisces sun/rmi
diff --git a/jdk/test/com/apple/eawt/DefaultMenuBar/DefaultMenuBarTest.java b/jdk/test/com/apple/eawt/DefaultMenuBar/DefaultMenuBarTest.java
index 943b494a3b..0ca31c4f6b 100644
--- a/jdk/test/com/apple/eawt/DefaultMenuBar/DefaultMenuBarTest.java
+++ b/jdk/test/com/apple/eawt/DefaultMenuBar/DefaultMenuBarTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8007267
* @summary [macosx] com.apple.eawt.Application.setDefaultMenuBar is not working
* @requires (os.family == "mac")
diff --git a/jdk/test/com/apple/laf/ScreenMenu/ScreenMenuMemoryLeakTest.java b/jdk/test/com/apple/laf/ScreenMenu/ScreenMenuMemoryLeakTest.java
index 9971967bbb..8aabcae42c 100644
--- a/jdk/test/com/apple/laf/ScreenMenu/ScreenMenuMemoryLeakTest.java
+++ b/jdk/test/com/apple/laf/ScreenMenu/ScreenMenuMemoryLeakTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016 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
@@ -20,16 +20,13 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
+/*
* @test
- * @key headful
* @bug 8158325
* @summary Memory leak in com.apple.laf.ScreenMenu: removed JMenuItems are still referenced
* @requires (os.family == "mac")
* @run main/timeout=300/othervm -Xmx16m ScreenMenuMemoryLeakTest
*/
-
import java.awt.EventQueue;
import java.lang.ref.WeakReference;
import java.lang.reflect.InvocationTargetException;
@@ -105,4 +102,4 @@ public class ScreenMenuMemoryLeakTest {
Objects.requireNonNull(menuItem, "The menu item should still be available at this point");
sMenu.remove(menuItem);
}
-}
+}
\ No newline at end of file
diff --git a/jdk/test/java/awt/Desktop/DesktopGtkLoadTest/DesktopGtkLoadTest.java b/jdk/test/java/awt/Desktop/DesktopGtkLoadTest/DesktopGtkLoadTest.java
index 61bd013b9d..8a463554ad 100644
--- a/jdk/test/java/awt/Desktop/DesktopGtkLoadTest/DesktopGtkLoadTest.java
+++ b/jdk/test/java/awt/Desktop/DesktopGtkLoadTest/DesktopGtkLoadTest.java
@@ -21,9 +21,7 @@
* questions.
*/
-/**
- * @test
- * @key headful
+/* @test
* @bug 8157827
* @summary AWT_Desktop/Automated/Exceptions/BasicTest loads incorrect GTK
* version when jdk.gtk.version=3
diff --git a/jdk/test/java/awt/Dialog/CloseDialog/CloseDialogTest.java b/jdk/test/java/awt/Dialog/CloseDialog/CloseDialogTest.java
index 694d6e3fbd..0a6288d896 100644
--- a/jdk/test/java/awt/Dialog/CloseDialog/CloseDialogTest.java
+++ b/jdk/test/java/awt/Dialog/CloseDialog/CloseDialogTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -30,7 +30,6 @@ import java.util.concurrent.atomic.AtomicReference;
/**
* @test
- * @key headful
* @bug 8043705
* @summary Can't exit color chooser dialog when running as an applet
* @run main CloseDialogTest
diff --git a/jdk/test/java/awt/EmbeddedFrame/DisplayChangedTest/DisplayChangedTest.java b/jdk/test/java/awt/EmbeddedFrame/DisplayChangedTest/DisplayChangedTest.java
index 5f347c8f0d..04f2f24b41 100644
--- a/jdk/test/java/awt/EmbeddedFrame/DisplayChangedTest/DisplayChangedTest.java
+++ b/jdk/test/java/awt/EmbeddedFrame/DisplayChangedTest/DisplayChangedTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, 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
@@ -21,17 +21,21 @@
* questions.
*/
+/*
+ @test
+ @bug 4980592
+ @summary switching user in XP causes an NPE in
+ sun.awt.windows.WWindowPeer.displayChanged
+ @requires (os.family == "windows")
+ @author [email protected]: area=embedded
+ @run main DisplayChangedTest
+ */
/**
- * @test
- * @key headful
- * @bug 4980592
- * @summary switching user in XP causes an NPE in
- * sun.awt.windows.WWindowPeer.displayChanged
- * @requires (os.family == "windows")
- * @author [email protected]: area=embedded
- * @run main DisplayChangedTest
+ * DisplayChangedTest.java
+ *
+ * summary: switching user in XP causes an NPE in
+ * sun.awt.windows.WWindowPeer.displayChanged
*/
-
import java.awt.Frame;
import java.awt.Dialog;
import java.awt.TextArea;
diff --git a/jdk/test/java/awt/EmbeddedFrame/EmbeddedFrameGrabTest/EmbeddedFrameGrabTest.java b/jdk/test/java/awt/EmbeddedFrame/EmbeddedFrameGrabTest/EmbeddedFrameGrabTest.java
index cce0353775..1613a80426 100644
--- a/jdk/test/java/awt/EmbeddedFrame/EmbeddedFrameGrabTest/EmbeddedFrameGrabTest.java
+++ b/jdk/test/java/awt/EmbeddedFrame/EmbeddedFrameGrabTest/EmbeddedFrameGrabTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, 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
@@ -21,16 +21,19 @@
* questions.
*/
+/*
+ @test
+ @bug 6345002
+ @summary grab problems with EmbeddedFrame
+ @requires (os.family == "windows")
+ @author [email protected] area=EmbeddedFrame
+ @run main EmbeddedFrameGrabTest
+ */
/**
- * @test
- * @key headful
- * @bug 6345003
- * @summary grab problems with EmbeddedFrame
- * @requires (os.family == "windows")
- * @author [email protected] area=EmbeddedFrame
- * @run main EmbeddedFrameGrabTest
+ * EmbeddedFrameGrabTest.java
+ *
+ * summary: grab problems with EmbeddedFrame
*/
-
import java.awt.Frame;
import java.awt.peer.FramePeer;
import javax.swing.JComboBox;
diff --git a/jdk/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html b/jdk/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html
index 31e7015c17..3e8611d2e0 100644
--- a/jdk/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html
+++ b/jdk/test/java/awt/EventDispatchThread/LoopRobustness/LoopRobustness.html
@@ -1,5 +1,5 @@
<!--
- Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
+ Copyright (c) 1998, 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
@@ -23,7 +23,6 @@
<HTML>
<!-- @test
- @key headful
@bug 4023283
@summary Checks that an Error which propogate up to the EventDispatch
loop does not crash AWT.
diff --git a/jdk/test/java/awt/EventQueue/6980209/bug6980209.java b/jdk/test/java/awt/EventQueue/6980209/bug6980209.java
index 5e058ee460..0f1080cba0 100644
--- a/jdk/test/java/awt/EventQueue/6980209/bug6980209.java
+++ b/jdk/test/java/awt/EventQueue/6980209/bug6980209.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,13 +21,11 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6980209
- * @summary Make tracking SecondaryLoop.enter/exit methods easier
- * @author Semyon Sadetsky
- */
+/* @test
+ @bug 6980209
+ @summary Make tracking SecondaryLoop.enter/exit methods easier
+ @author Semyon Sadetsky
+ */
import javax.swing.*;
import java.awt.*;
diff --git a/jdk/test/java/awt/Focus/FocusEmbeddedFrameTest/FocusEmbeddedFrameTest.java b/jdk/test/java/awt/Focus/FocusEmbeddedFrameTest/FocusEmbeddedFrameTest.java
index b6b1c8cea3..999d9ac332 100644
--- a/jdk/test/java/awt/Focus/FocusEmbeddedFrameTest/FocusEmbeddedFrameTest.java
+++ b/jdk/test/java/awt/Focus/FocusEmbeddedFrameTest/FocusEmbeddedFrameTest.java
@@ -21,17 +21,15 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6516675
- * @summary Tests that EmbeddedFrame can be focused.
- * @author anton.tarasov: area=awt-focus
- * @requires (os.family == "windows")
- * @library ../../regtesthelpers
- * @build Util UtilInternal
- * @run main FocusEmbeddedFrameTest
- */
+/*
+ @test
+ @bug 6516675
+ @summary Tests that EmbeddedFrame can be focused.
+ @author anton.tarasov: area=awt-focus
+ @library ../../regtesthelpers
+ @build Util UtilInternal
+ @run main FocusEmbeddedFrameTest
+*/
import java.awt.*;
import java.awt.event.*;
diff --git a/jdk/test/java/awt/FontClass/HelvLtOblTest.java b/jdk/test/java/awt/FontClass/HelvLtOblTest.java
index f57d3f0eac..80f976a76f 100644
--- a/jdk/test/java/awt/FontClass/HelvLtOblTest.java
+++ b/jdk/test/java/awt/FontClass/HelvLtOblTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8064833
* @summary Test correct font is obtained via family+style
* @run main HelvLtOblTest
diff --git a/jdk/test/java/awt/FontClass/SurrogateTest/SuppCharTest.java b/jdk/test/java/awt/FontClass/SurrogateTest/SuppCharTest.java
index 98b02cd419..1011b741bb 100644
--- a/jdk/test/java/awt/FontClass/SurrogateTest/SuppCharTest.java
+++ b/jdk/test/java/awt/FontClass/SurrogateTest/SuppCharTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8015556
* @summary Surrogate pairs do not render properly on MacOS X.
*/
diff --git a/jdk/test/java/awt/Frame/ExceptionOnSetExtendedStateTest/ExceptionOnSetExtendedStateTest.java b/jdk/test/java/awt/Frame/ExceptionOnSetExtendedStateTest/ExceptionOnSetExtendedStateTest.java
index 8d73915a8d..845138ab3b 100644
--- a/jdk/test/java/awt/Frame/ExceptionOnSetExtendedStateTest/ExceptionOnSetExtendedStateTest.java
+++ b/jdk/test/java/awt/Frame/ExceptionOnSetExtendedStateTest/ExceptionOnSetExtendedStateTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -21,14 +21,12 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 8032078
- * @summary Frame.setExtendedState throws RuntimeException, if
- * windowState=ICONIFIED|MAXIMIZED_BOTH, on OS X
- * @author Anton Litvinov
- */
+/* @test
+ @bug 8032078
+ @summary Frame.setExtendedState throws RuntimeException, if
+ windowState=ICONIFIED|MAXIMIZED_BOTH, on OS X
+ @author Anton Litvinov
+*/
import java.awt.*;
diff --git a/jdk/test/java/awt/Frame/MaximizedByPlatform/MaximizedByPlatform.java b/jdk/test/java/awt/Frame/MaximizedByPlatform/MaximizedByPlatform.java
index 4554c61869..224c10e799 100644
--- a/jdk/test/java/awt/Frame/MaximizedByPlatform/MaximizedByPlatform.java
+++ b/jdk/test/java/awt/Frame/MaximizedByPlatform/MaximizedByPlatform.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,9 +21,7 @@
* questions.
*/
-/**
- * @test
- * @key headful
+/* @test
* @bug 8026143
* @summary [macosx] Maximized state could be inconsistent between peer and frame
* @author Petr Pchelko
@@ -72,7 +70,7 @@ public class MaximizedByPlatform {
throw new RuntimeException("Maximized state was not set for frame in setBounds");
}
} finally {
- if (frame != null) frame.dispose();
+ frame.dispose();
}
@@ -89,7 +87,7 @@ public class MaximizedByPlatform {
throw new RuntimeException("Maximized state was not set for frame in setVisible");
}
} finally {
- if (frame != null) frame.dispose();
+ frame.dispose();
}
}
diff --git a/jdk/test/java/awt/Frame/MaximizedToIconified/MaximizedToIconified.java b/jdk/test/java/awt/Frame/MaximizedToIconified/MaximizedToIconified.java
index ebf1443294..1cb281368a 100644
--- a/jdk/test/java/awt/Frame/MaximizedToIconified/MaximizedToIconified.java
+++ b/jdk/test/java/awt/Frame/MaximizedToIconified/MaximizedToIconified.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2016, 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
@@ -22,16 +22,17 @@
*/
/*
- * @test
- * @key headful
- * @bug 4977491 8160767
- * @summary State changes should always be reported as events
- * @library ../../../../lib/testlibrary
- * @build ExtendedRobot
- * @run main MaximizedToIconified
- */
+ @test
+ @key headful
+ @bug 4977491
+ @summary State changes should always be reported as events
+ @author anthony.petrov@...: area=awt.toplevel
+ @library ../../regtesthelpers
+ @build Util
+ @run main MaximizedToIconified
+*/
-/*
+/**
* MaximizedToIconified.java
*
* summary: Invoking setExtendedState(ICONIFIED) on a maximized
@@ -39,91 +40,395 @@
* states in the newState of the state change event.
*/
-import java.awt.Frame;
-import java.awt.Toolkit;
-import java.awt.event.WindowEvent;
-import java.awt.event.WindowStateListener;
+import java.awt.*;
+import java.awt.event.*;
+import java.util.*;
+import test.java.awt.regtesthelpers.Util;
+
public class MaximizedToIconified
{
static volatile int lastFrameState = Frame.NORMAL;
static volatile boolean failed = false;
static volatile Toolkit myKit;
- private static ExtendedRobot robot;
- private static void checkState(Frame frame, int state) {
- frame.setExtendedState(state);
- robot.waitForIdle();
- robot.delay(100);
+ private static void checkState(Frame f, int state) {
+ f.setExtendedState(state);
+ Util.waitForIdle(null);
- System.out.println("state = " + state + "; getExtendedState() = " + frame.getExtendedState());
+ System.out.println("state = " + state + "; getExtendedState() = " + f.getExtendedState());
if (failed) {
- frame.dispose();
- throw new RuntimeException("getOldState() != previous getNewState() in WINDOW_STATE_CHANGED event.");
+ MaximizedToIconified.fail("getOldState() != previous getNewState() in WINDOW_STATE_CHANGED event.");
}
- if (lastFrameState != frame.getExtendedState()) {
- frame.dispose();
- throw new RuntimeException("getExtendedState() != last getNewState() in WINDOW_STATE_CHANGED event.");
+ if (lastFrameState != f.getExtendedState()) {
+ MaximizedToIconified.fail("getExtendedState() != last getNewState() in WINDOW_STATE_CHANGED event.");
}
- if (frame.getExtendedState() != state) {
- frame.dispose();
- throw new RuntimeException("getExtendedState() != " + state + " as expected.");
+ if (f.getExtendedState() != state) {
+ MaximizedToIconified.fail("getExtendedState() != " + state + " as expected.");
}
+ // Plain return means the check passed
}
- private static void examineStates(int states[]) {
+ private static void examineStates(Frame f_arg, int states[]) {
+ Frame f = f_arg;
- Frame frame = new Frame("test");
- frame.setSize(200, 200);
- frame.setVisible(true);
+ if (f == null) {
+ f = new Frame("test");
+ f.setSize(200, 200);
+ f.setVisible(true);
+ }
- robot.waitForIdle();
+ Util.waitForIdle(null);
- frame.addWindowStateListener(new WindowStateListener() {
+ f.addWindowStateListener(new WindowStateListener() {
public void windowStateChanged(WindowEvent e) {
- System.out.println("last = " + lastFrameState + "; getOldState() = " + e.getOldState() +
- "; getNewState() = " + e.getNewState());
+ System.out.println("last = " + lastFrameState + "; getOldState() = " + e.getOldState() + "; getNewState() = " + e.getNewState());
if (e.getOldState() == lastFrameState) {
lastFrameState = e.getNewState();
} else {
- System.out.println("Wrong getOldState(): expected = " + lastFrameState + "; received = " +
- e.getOldState());
+ System.out.println("Wrong getOldState(): expected = " + lastFrameState + "; received = " + e.getOldState());
failed = true;
}
}
});
- for (int state : states) {
+ for (int state: states) {
if (myKit.isFrameStateSupported(state)) {
- checkState(frame, state);
+ checkState(f, state);
} else {
System.out.println("Frame state = " + state + " is NOT supported by the native system. The state is skipped.");
}
}
- if (frame != null) {
- frame.dispose();
+ if (f_arg == null) {
+ f.dispose();
}
}
- private static void doTest() {
+ private static void init()
+ {
+ String[] instructions =
+ {
+ "This is an AUTOMATIC test, simply wait until it is done.",
+ "The result (passed or failed) will be shown in the",
+ "message window below."
+ };
+ Sysout.createDialog( );
+ Sysout.printInstructions( instructions );
myKit = Toolkit.getDefaultToolkit();
// NOTE! Compound states (like MAXIMIZED_BOTH | ICONIFIED) CANNOT be used,
// because Toolkit.isFrameStateSupported() method reports these states
// as not supported. And such states will simply be skipped.
- examineStates(new int[] {Frame.MAXIMIZED_BOTH, Frame.ICONIFIED, Frame.NORMAL});
- examineStates(new int[] {Frame.ICONIFIED, Frame.MAXIMIZED_BOTH, Frame.NORMAL});
+ examineStates(null, new int[] {Frame.MAXIMIZED_BOTH, Frame.ICONIFIED, Frame.NORMAL});
+ examineStates(null, new int[] {Frame.ICONIFIED, Frame.MAXIMIZED_BOTH, Frame.NORMAL});
+
+
+ MaximizedToIconified.pass();
+
+ }//End init()
+
+
+
+ /*****************************************************
+ * Standard Test Machinery Section
+ * DO NOT modify anything in this section -- it's a
+ * standard chunk of code which has all of the
+ * synchronisation necessary for the test harness.
+ * By keeping it the same in all tests, it is easier
+ * to read and understand someone else's test, as
+ * well as insuring that all tests behave correctly
+ * with the test harness.
+ * There is a section following this for test-
+ * classes
+ ******************************************************/
+ private static boolean theTestPassed = false;
+ private static boolean testGeneratedInterrupt = false;
+ private static String failureMessage = "";
+
+ private static Thread mainThread = null;
+
+ private static int sleepTime = 300000;
+
+ // Not sure about what happens if multiple of this test are
+ // instantiated in the same VM. Being static (and using
+ // static vars), it aint gonna work. Not worrying about
+ // it for now.
+ public static void main( String args[] ) throws InterruptedException
+ {
+ mainThread = Thread.currentThread();
+ try
+ {
+ init();
+ }
+ catch( TestPassedException e )
+ {
+ //The test passed, so just return from main and harness will
+ // interepret this return as a pass
+ return;
+ }
+ //At this point, neither test pass nor test fail has been
+ // called -- either would have thrown an exception and ended the
+ // test, so we know we have multiple threads.
+
+ //Test involves other threads, so sleep and wait for them to
+ // called pass() or fail()
+ try
+ {
+ Thread.sleep( sleepTime );
+ //Timed out, so fail the test
+ throw new RuntimeException( "Timed out after " + sleepTime/1000 + " seconds" );
+ }
+ catch (InterruptedException e)
+ {
+ //The test harness may have interrupted the test. If so, rethrow the exception
+ // so that the harness gets it and deals with it.
+ if( ! testGeneratedInterrupt ) throw e;
+
+ //reset flag in case hit this code more than once for some reason (just safety)
+ testGeneratedInterrupt = false;
+
+ if ( theTestPassed == false )
+ {
+ throw new RuntimeException( failureMessage );
+ }
+ }
+
+ }//main
+ public static synchronized void setTimeoutTo( int seconds )
+ {
+ sleepTime = seconds * 1000;
}
- public static void main( String args[] ) throws Exception
+ public static synchronized void pass()
{
- robot = new ExtendedRobot();
- doTest();
+ Sysout.println( "The test passed." );
+ Sysout.println( "The test is over, hit Ctl-C to stop Java VM" );
+ //first check if this is executing in main thread
+ if ( mainThread == Thread.currentThread() )
+ {
+ //Still in the main thread, so set the flag just for kicks,
+ // and throw a test passed exception which will be caught
+ // and end the test.
+ theTestPassed = true;
+ throw new TestPassedException();
+ }
+ theTestPassed = true;
+ testGeneratedInterrupt = true;
+ mainThread.interrupt();
+ }//pass()
+ public static synchronized void fail()
+ {
+ //test writer didn't specify why test failed, so give generic
+ fail( "it just plain failed! :-)" );
}
+ public static synchronized void fail( String whyFailed )
+ {
+ Sysout.println( "The test failed: " + whyFailed );
+ Sysout.println( "The test is over, hit Ctl-C to stop Java VM" );
+ //check if this called from main thread
+ if ( mainThread == Thread.currentThread() )
+ {
+ //If main thread, fail now 'cause not sleeping
+ throw new RuntimeException( whyFailed );
+ }
+ theTestPassed = false;
+ testGeneratedInterrupt = true;
+ failureMessage = whyFailed;
+ mainThread.interrupt();
+ }//fail()
+
+}// class MaximizedToIconified
+
+//This exception is used to exit from any level of call nesting
+// when it's determined that the test has passed, and immediately
+// end the test.
+class TestPassedException extends RuntimeException
+{
}
+
+//*********** End Standard Test Machinery Section **********
+
+
+//************ Begin classes defined for the test ****************
+
+// if want to make listeners, here is the recommended place for them, then instantiate
+// them in init()
+
+/* Example of a class which may be written as part of a test
+class NewClass implements anInterface
+ {
+ static int newVar = 0;
+
+ public void eventDispatched(AWTEvent e)
+ {
+ //Counting events to see if we get enough
+ eventCount++;
+
+ if( eventCount == 20 )
+ {
+ //got enough events, so pass
+
+ MaximizedToIconified.pass();
+ }
+ else if( tries == 20 )
+ {
+ //tried too many times without getting enough events so fail
+
+ MaximizedToIconified.fail();
+ }
+
+ }// eventDispatched()
+
+ }// NewClass class
+
+*/
+
+
+//************** End classes defined for the test *******************
+
+
+
+
+/****************************************************
+ Standard Test Machinery
+ DO NOT modify anything below -- it's a standard
+ chunk of code whose purpose is to make user
+ interaction uniform, and thereby make it simpler
+ to read and understand someone else's test.
+ ****************************************************/
+
+/**
+ This is part of the standard test machinery.
+ It creates a dialog (with the instructions), and is the interface
+ for sending text messages to the user.
+ To print the instructions, send an array of strings to Sysout.createDialog
+ WithInstructions method. Put one line of instructions per array entry.
+ To display a message for the tester to see, simply call Sysout.println
+ with the string to be displayed.
+ This mimics System.out.println but works within the test harness as well
+ as standalone.
+ */
+
+class Sysout
+{
+ private static TestDialog dialog;
+
+ public static void createDialogWithInstructions( String[] instructions )
+ {
+ dialog = new TestDialog( new Frame(), "Instructions" );
+ dialog.printInstructions( instructions );
+ dialog.setVisible(true);
+ println( "Any messages for the tester will display here." );
+ }
+
+ public static void createDialog( )
+ {
+ dialog = new TestDialog( new Frame(), "Instructions" );
+ String[] defInstr = { "Instructions will appear here. ", "" } ;
+ dialog.printInstructions( defInstr );
+ dialog.setVisible(true);
+ println( "Any messages for the tester will display here." );
+ }
+
+
+ public static void printInstructions( String[] instructions )
+ {
+ dialog.printInstructions( instructions );
+ }
+
+
+ public static void println( String messageIn )
+ {
+ dialog.displayMessage( messageIn );
+ System.out.println(messageIn);
+ }
+
+}// Sysout class
+
+/**
+ This is part of the standard test machinery. It provides a place for the
+ test instructions to be displayed, and a place for interactive messages
+ to the user to be displayed.
+ To have the test instructions displayed, see Sysout.
+ To have a message to the user be displayed, see Sysout.
+ Do not call anything in this dialog directly.
+ */
+class TestDialog extends Dialog
+{
+
+ TextArea instructionsText;
+ TextArea messageText;
+ int maxStringLength = 80;
+
+ //DO NOT call this directly, go through Sysout
+ public TestDialog( Frame frame, String name )
+ {
+ super( frame, name );
+ int scrollBoth = TextArea.SCROLLBARS_BOTH;
+ instructionsText = new TextArea( "", 15, maxStringLength, scrollBoth );
+ add( "North", instructionsText );
+
+ messageText = new TextArea( "", 5, maxStringLength, scrollBoth );
+ add("Center", messageText);
+
+ pack();
+
+ setVisible(true);
+ }// TestDialog()
+
+ //DO NOT call this directly, go through Sysout
+ public void printInstructions( String[] instructions )
+ {
+ //Clear out any current instructions
+ instructionsText.setText( "" );
+
+ //Go down array of instruction strings
+
+ String printStr, remainingStr;
+ for( int i=0; i < instructions.length; i++ )
+ {
+ //chop up each into pieces maxSringLength long
+ remainingStr = instructions[ i ];
+ while( remainingStr.length() > 0 )
+ {
+ //if longer than max then chop off first max chars to print
+ if( remainingStr.length() >= maxStringLength )
+ {
+ //Try to chop on a word boundary
+ int posOfSpace = remainingStr.
+ lastIndexOf( ' ', maxStringLength - 1 );
+
+ if( posOfSpace <= 0 ) posOfSpace = maxStringLength - 1;
+
+ printStr = remainingStr.substring( 0, posOfSpace + 1 );
+ remainingStr = remainingStr.substring( posOfSpace + 1 );
+ }
+ //else just print
+ else
+ {
+ printStr = remainingStr;
+ remainingStr = "";
+ }
+
+ instructionsText.append( printStr + "\n" );
+
+ }// while
+
+ }// for
+
+ }//printInstructions()
+
+ //DO NOT call this directly, go through Sysout
+ public void displayMessage( String messageIn )
+ {
+ messageText.append( messageIn + "\n" );
+ System.out.println(messageIn);
+ }
+
+}// TestDialog class
diff --git a/jdk/test/java/awt/Frame/NormalToIconified/NormalToIconifiedTest.java b/jdk/test/java/awt/Frame/NormalToIconified/NormalToIconifiedTest.java
index ef926c8fce..31e85c2b58 100644
--- a/jdk/test/java/awt/Frame/NormalToIconified/NormalToIconifiedTest.java
+++ b/jdk/test/java/awt/Frame/NormalToIconified/NormalToIconifiedTest.java
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8171949 8214046
* @summary Tests that bitwise mask is set and state listener is notified during state transition.
* @author Dmitry Markov
diff --git a/jdk/test/java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java b/jdk/test/java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java
index 8347395769..da5b3800ea 100644
--- a/jdk/test/java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java
+++ b/jdk/test/java/awt/Frame/SetMaximizedBounds/SetMaximizedBounds.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,9 +23,8 @@
import java.awt.*;
-/**
+/*
* @test
- * @key headful
* @summary When Frame.setExtendedState(Frame.MAXIMIZED_BOTH)
* is called for a Frame after been called setMaximizedBounds() with
* certain value, Frame bounds must equal to this value.
diff --git a/jdk/test/java/awt/Frame/WindowDragTest/WindowDragTest.java b/jdk/test/java/awt/Frame/WindowDragTest/WindowDragTest.java
index ee21c1e169..e7b0970b0f 100644
--- a/jdk/test/java/awt/Frame/WindowDragTest/WindowDragTest.java
+++ b/jdk/test/java/awt/Frame/WindowDragTest/WindowDragTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,16 +21,15 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 7128738 7161759
- * @summary dragged dialog freezes system on dispose
- * @author Oleg Pekhovskiy: area=awt.toplevel
- * @library ../../regtesthelpers
- * @build Util
- * @run main WindowDragTest
- */
+/*
+ @test
+ @bug 7128738 7161759
+ @summary dragged dialog freezes system on dispose
+ @author Oleg Pekhovskiy: area=awt.toplevel
+ @library ../../regtesthelpers
+ @build Util
+ @run main WindowDragTest
+*/
import java.awt.Frame;
import java.awt.event.InputEvent;
diff --git a/jdk/test/java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java b/jdk/test/java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java
index 217b20ef70..93f481ff02 100644
--- a/jdk/test/java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java
+++ b/jdk/test/java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,16 +21,15 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6741526
- * @summary KeyboardFocusManager.setDefaultFocusTraversalPolicy(FocusTraversalPolicy) affects created components
- * @library ../../regtesthelpers
- * @build Sysout
- * @author Andrei Dmitriev : area=awt-focus
- * @run main DefaultPolicyChange_Swing
- */
+/*
+ @test
+ @bug 6741526
+ @summary KeyboardFocusManager.setDefaultFocusTraversalPolicy(FocusTraversalPolicy) affects created components
+ @library ../../regtesthelpers
+ @build Sysout
+ @author Andrei Dmitriev : area=awt-focus
+ @run main DefaultPolicyChange_Swing
+*/
import java.awt.*;
import javax.swing.*;
diff --git a/jdk/test/java/awt/MenuBar/8007006/bug8007006.java b/jdk/test/java/awt/MenuBar/8007006/bug8007006.java
index 8965894566..c443336195 100644
--- a/jdk/test/java/awt/MenuBar/8007006/bug8007006.java
+++ b/jdk/test/java/awt/MenuBar/8007006/bug8007006.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8007006
* @summary [macosx] Closing subwindow loses main window menus.
* @author Leonid Romanov
diff --git a/jdk/test/java/awt/Mouse/EnterExitEvents/FullscreenEnterEventTest.java b/jdk/test/java/awt/Mouse/EnterExitEvents/FullscreenEnterEventTest.java
index 6d2b169343..af5fa04769 100644
--- a/jdk/test/java/awt/Mouse/EnterExitEvents/FullscreenEnterEventTest.java
+++ b/jdk/test/java/awt/Mouse/EnterExitEvents/FullscreenEnterEventTest.java
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+* Copyright (c) 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
@@ -33,9 +33,8 @@ import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
-/**
+/*
* @test
- * @key headful
* @bug 8013468
* @summary Cursor does not update properly when in fullscreen mode on Mac
* The core reason of the issue was the lack of a mouse entered event in fullscreen
@@ -45,7 +44,6 @@ import java.lang.reflect.Proxy;
* @author Petr Pchelko area=awt.event
* @run main FullscreenEnterEventTest
*/
-
public class FullscreenEnterEventTest {
private static String OS = System.getProperty("os.name").toLowerCase();
diff --git a/jdk/test/java/awt/SplashScreen/FullscreenAfterSplash/FullScreenAfterSplash.java b/jdk/test/java/awt/SplashScreen/FullscreenAfterSplash/FullScreenAfterSplash.java
index 32e4be6e67..15acb69913 100644
--- a/jdk/test/java/awt/SplashScreen/FullscreenAfterSplash/FullScreenAfterSplash.java
+++ b/jdk/test/java/awt/SplashScreen/FullscreenAfterSplash/FullScreenAfterSplash.java
@@ -35,9 +35,8 @@ import javax.swing.JFrame;
import javax.swing.SwingUtilities;
import javax.swing.WindowConstants;
-/**
+/*
* @test
- * @key headful
* @bug 8024185
* @summary Native Mac OS X full screen does not work after showing the splash
* @requires (os.family == "mac")
@@ -47,7 +46,6 @@ import javax.swing.WindowConstants;
* @author Petr Pchelko area=awt.event
* @run main/othervm -splash:test.png FullScreenAfterSplash
*/
-
public class FullScreenAfterSplash {
private static JFrame frame;
diff --git a/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.java b/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.java
index fc3945a782..83d5bc098e 100644
--- a/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.java
+++ b/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 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
@@ -21,6 +21,16 @@
* questions.
*/
+/*
+ test
+ @bug 6193279
+ @summary REGRESSION: AppletViewer throws IOException when path is encoded URL
+ @author Dmitry Cherepanov: area=appletviewer
+ @run compile IOExceptionIfEncodedURLTest.java
+ @run main IOExceptionIfEncodedURLTest
+ @run shell IOExceptionIfEncodedURLTest.sh
+*/
+
import java.applet.Applet;
import sun.net.www.ParseUtil;
import java.io.File;
diff --git a/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.sh b/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.sh
index dd7a340ab2..c6ce7064ae 100644
--- a/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.sh
+++ b/jdk/test/java/awt/appletviewer/IOExceptionIfEncodedURLTest/IOExceptionIfEncodedURLTest.sh
@@ -24,8 +24,7 @@
#!/bin/ksh -p
#
# @test IOExceptionIfEncodedURLTest.sh
-# @key headful
-# @bug 6193279 6619458 8137087 8186259
+# @bug 6193279 6619458 8137087
# @summary REGRESSION: AppletViewer throws IOException when path is encoded URL
# @author Dmitry Cherepanov: area=appletviewer
# @run compile IOExceptionIfEncodedURLTest.java
diff --git a/jdk/test/java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java b/jdk/test/java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java
index aa49f4fcbd..d47a7b0293 100644
--- a/jdk/test/java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java
+++ b/jdk/test/java/awt/datatransfer/DragImage/MultiResolutionDragImageTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -32,7 +32,6 @@ import static java.awt.event.InputEvent.BUTTON1_DOWN_MASK;
/**
* @test
- * @key headful
* @bug 8076106
* @author Hendrik Schreiber
* @summary [macosx] Drag image of TransferHandler does not honor
diff --git a/jdk/test/java/awt/datatransfer/HTMLDataFlavors/HTMLDataFlavorTest.java b/jdk/test/java/awt/datatransfer/HTMLDataFlavors/HTMLDataFlavorTest.java
index a5677e87e3..1fe616abbc 100644
--- a/jdk/test/java/awt/datatransfer/HTMLDataFlavors/HTMLDataFlavorTest.java
+++ b/jdk/test/java/awt/datatransfer/HTMLDataFlavors/HTMLDataFlavorTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,17 +21,15 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 7075105
- * @summary WIN: Provide a way to format HTML on drop
- * @author Denis Fokin: area=datatransfer
- * @requires (os.family == "windows")
- * @build HtmlTransferable PutAllHtmlFlavorsOnClipboard
- * @build PutOnlyAllHtmlFlavorOnClipboard PutSelectionAndFragmentHtmlFlavorsOnClipboard
- * @run main HTMLDataFlavorTest
- */
+/*
+ @test
+ @bug 7075105
+ @summary WIN: Provide a way to format HTML on drop
+ @author Denis Fokin: area=datatransfer
+ @build HtmlTransferable PutAllHtmlFlavorsOnClipboard
+ @build PutOnlyAllHtmlFlavorOnClipboard PutSelectionAndFragmentHtmlFlavorsOnClipboard
+ @run main HTMLDataFlavorTest
+*/
import java.awt.*;
import java.awt.datatransfer.*;
diff --git a/jdk/test/java/awt/event/KeyEvent/8020209/bug8020209.java b/jdk/test/java/awt/event/KeyEvent/8020209/bug8020209.java
index bb3e68b974..21426bdf96 100644
--- a/jdk/test/java/awt/event/KeyEvent/8020209/bug8020209.java
+++ b/jdk/test/java/awt/event/KeyEvent/8020209/bug8020209.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8020209
* @summary [macosx] Mac OS X key event confusion for "COMMAND PLUS"
* @author [email protected]
diff --git a/jdk/test/java/awt/event/KeyEvent/DeadKey/DeadKeyMacOSXInputText.java b/jdk/test/java/awt/event/KeyEvent/DeadKey/DeadKeyMacOSXInputText.java
index a0f5c5a226..1a42a6e919 100644
--- a/jdk/test/java/awt/event/KeyEvent/DeadKey/DeadKeyMacOSXInputText.java
+++ b/jdk/test/java/awt/event/KeyEvent/DeadKey/DeadKeyMacOSXInputText.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 7199180
* @summary [macosx] Dead keys handling for input methods
* @author alexandr.scherbatiy area=awt.event
@@ -31,7 +30,6 @@
* @build jdk.testlibrary.OSInfo
* @run main DeadKeyMacOSXInputText
*/
-
import java.awt.*;
import java.awt.event.*;
import java.awt.event.KeyEvent;
diff --git a/jdk/test/java/awt/event/KeyEvent/DeadKey/deadKeyMacOSX.java b/jdk/test/java/awt/event/KeyEvent/DeadKey/deadKeyMacOSX.java
index c90a1131a0..f5b9a96115 100644
--- a/jdk/test/java/awt/event/KeyEvent/DeadKey/deadKeyMacOSX.java
+++ b/jdk/test/java/awt/event/KeyEvent/DeadKey/deadKeyMacOSX.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 7196547
* @summary Dead Key implementation for KeyEvent on Mac OS X
* @author alexandr.scherbatiy area=awt.event
diff --git a/jdk/test/java/awt/font/TextLayout/TestSinhalaChar.java b/jdk/test/java/awt/font/TextLayout/TestSinhalaChar.java
index 5ff5a4b5bd..d104b6a4c1 100644
--- a/jdk/test/java/awt/font/TextLayout/TestSinhalaChar.java
+++ b/jdk/test/java/awt/font/TextLayout/TestSinhalaChar.java
@@ -21,9 +21,7 @@
*
*/
-/**
- * @test
- * @key headful
+/* @test
* @summary verify lack of crash on U+0DDD.
* @bug 6795060
*/
diff --git a/jdk/test/java/awt/im/6396526/IMLookAndFeel.java b/jdk/test/java/awt/im/6396526/IMLookAndFeel.java
index 179324b877..e456048e38 100644
--- a/jdk/test/java/awt/im/6396526/IMLookAndFeel.java
+++ b/jdk/test/java/awt/im/6396526/IMLookAndFeel.java
@@ -21,13 +21,12 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
- * @bug 6396526
- * @summary Verify below-the-spot IM in the swing L&F JFrame.
- * Although the swing component is decorated with L&F
- * the IM window should have no decoration.
+ * @bug 6396526
+ * @summary Verify below-the-spot IM in the swing L&F JFrame.
+ * Although the swing component is decorated with L&F
+ * the IM window should have no decoration.
* @author yuriko.yamasaki
*/
diff --git a/jdk/test/java/awt/im/8041990/bug8041990.java b/jdk/test/java/awt/im/8041990/bug8041990.java
index 9398fa3aab..ee813e6715 100644
--- a/jdk/test/java/awt/im/8041990/bug8041990.java
+++ b/jdk/test/java/awt/im/8041990/bug8041990.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -22,14 +22,12 @@
*/
-/**
- * @test
- * @key headful
- * @bug 8041990
- * @summary Language specific keys does not work in applets when opened outside the browser
- * @author Petr Pchelko
- */
-
+/*
+ @test
+ @bug 8041990
+ @summary Language specific keys does not work in applets when opened outside the browser
+ @author Petr Pchelko
+*/
import sun.awt.SunToolkit;
diff --git a/jdk/test/java/awt/image/MultiResolutionImageTest.java b/jdk/test/java/awt/image/MultiResolutionImageTest.java
index e627bc3ae2..21864f9be5 100644
--- a/jdk/test/java/awt/image/MultiResolutionImageTest.java
+++ b/jdk/test/java/awt/image/MultiResolutionImageTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -45,7 +45,6 @@ import sun.awt.image.MultiResolutionImage;
/**
* @test
* @bug 8011059
- * @key headful
* @author Alexander Scherbatiy
* @summary [macosx] Make JDK demos look perfect on retina displays
* @run main MultiResolutionImageTest CUSTOM
@@ -53,7 +52,6 @@ import sun.awt.image.MultiResolutionImage;
* @run main MultiResolutionImageTest TOOLKIT_LOAD
* @run main MultiResolutionImageTest TOOLKIT
*/
-
public class MultiResolutionImageTest {
private static final int IMAGE_WIDTH = 300;
diff --git a/jdk/test/java/awt/image/multiresolution/MultiResolutionToolkitImageTest.java b/jdk/test/java/awt/image/multiresolution/MultiResolutionToolkitImageTest.java
index 9ff181922b..57a54386f0 100644
--- a/jdk/test/java/awt/image/multiresolution/MultiResolutionToolkitImageTest.java
+++ b/jdk/test/java/awt/image/multiresolution/MultiResolutionToolkitImageTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -36,13 +36,11 @@ import sun.awt.image.MultiResolutionToolkitImage;
/**
* @test
- * @key headful
* @bug 8040291
* @author Alexander Scherbatiy
* @summary [macosx] Http-Images are not fully loaded when using ImageIcon
* @run main MultiResolutionToolkitImageTest
*/
-
public class MultiResolutionToolkitImageTest {
private static final int IMAGE_WIDTH = 300;
diff --git a/jdk/test/java/awt/keyboard/AltPlusNumberKeyCombinationsTest/AltPlusNumberKeyCombinationsTest.java b/jdk/test/java/awt/keyboard/AltPlusNumberKeyCombinationsTest/AltPlusNumberKeyCombinationsTest.java
index 288b1bdadc..9088018e25 100644
--- a/jdk/test/java/awt/keyboard/AltPlusNumberKeyCombinationsTest/AltPlusNumberKeyCombinationsTest.java
+++ b/jdk/test/java/awt/keyboard/AltPlusNumberKeyCombinationsTest/AltPlusNumberKeyCombinationsTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -25,15 +25,16 @@ import java.awt.*;
import java.awt.event.*;
/**
- * @test
- * @key headful
- * @summary Test that it is possible to type "Alt code" on Windows.
- * @requires (os.family == "windows")
- * @library ../../../../lib/testlibrary
- * @build ExtendedRobot
- * @run main AltPlusNumberKeyCombinationsTest
+ * Test that it is possible to type "Alt code" on Windows.
+ * Windows-only test.
*/
-
+/*
+@test
+@summary Test that it is possible to type "Alt code" on Windows.
+@library ../../../../lib/testlibrary
+@build ExtendedRobot
+@run main AltPlusNumberKeyCombinationsTest
+*/
public class AltPlusNumberKeyCombinationsTest {
private Frame frame;
diff --git a/jdk/test/java/awt/print/PrinterJob/CheckPrivilege.java b/jdk/test/java/awt/print/PrinterJob/CheckPrivilege.java
index de32d587ad..1645c58583 100644
--- a/jdk/test/java/awt/print/PrinterJob/CheckPrivilege.java
+++ b/jdk/test/java/awt/print/PrinterJob/CheckPrivilege.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/**
* @test
- * @key printer
* @bug 4151151
* @summary Confirm that low-level print code does doPrivilege.
* @author Graham Hamilton
diff --git a/jdk/test/java/awt/print/PrinterJob/ExceptionTest.java b/jdk/test/java/awt/print/PrinterJob/ExceptionTest.java
index aec97c9be1..fbb22461c2 100644
--- a/jdk/test/java/awt/print/PrinterJob/ExceptionTest.java
+++ b/jdk/test/java/awt/print/PrinterJob/ExceptionTest.java
@@ -23,7 +23,6 @@
/**
* @test
- * @key printer
* @bug 6467557
* @summary No exception should be thrown.
* @run main ExceptionTest
diff --git a/jdk/test/java/awt/print/PrinterJob/ImagePrinting/NullClipARGB.java b/jdk/test/java/awt/print/PrinterJob/ImagePrinting/NullClipARGB.java
index f686e17701..88d4e43cf9 100644
--- a/jdk/test/java/awt/print/PrinterJob/ImagePrinting/NullClipARGB.java
+++ b/jdk/test/java/awt/print/PrinterJob/ImagePrinting/NullClipARGB.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/**
* @test
- * @key printer
* @bug 8061392
* @summary Test no NPE when printing transparency with null clip.
*/
diff --git a/jdk/test/java/awt/print/PrinterJob/Margins.java b/jdk/test/java/awt/print/PrinterJob/Margins.java
index 6803a5dc49..efdebe4c9e 100644
--- a/jdk/test/java/awt/print/PrinterJob/Margins.java
+++ b/jdk/test/java/awt/print/PrinterJob/Margins.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/**
* @test
- * @key headful
* @bug 6543815
* @summary Image should be sent to printer, no exceptions thrown.
* The 2 printouts should have a rectangle which is the minimum
diff --git a/jdk/test/java/awt/print/PrinterJob/PaintText.java b/jdk/test/java/awt/print/PrinterJob/PaintText.java
index 7f8047bd4c..15a5c288f3 100644
--- a/jdk/test/java/awt/print/PrinterJob/PaintText.java
+++ b/jdk/test/java/awt/print/PrinterJob/PaintText.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/**
* @test
- * @key headful printer
* @bug 6498340
* @summary No exception when printing text with a paint.
* @run main PaintText
diff --git a/jdk/test/java/awt/print/PrinterJob/PrintCrashTest.java b/jdk/test/java/awt/print/PrinterJob/PrintCrashTest.java
index 3a1bc4c8c1..a5f87cfce4 100644
--- a/jdk/test/java/awt/print/PrinterJob/PrintCrashTest.java
+++ b/jdk/test/java/awt/print/PrinterJob/PrintCrashTest.java
@@ -21,9 +21,9 @@
* questions.
*/
-/**
+/*
* @test
- * @key printer headful
+ * @key headful
* @bug 8163889
* @summary Printing crashes on OSX.
* @run main PrintCrashTest
diff --git a/jdk/test/java/awt/print/PrinterJob/PrintTextPane.java b/jdk/test/java/awt/print/PrinterJob/PrintTextPane.java
index b06d5c5182..878be7dd5a 100644
--- a/jdk/test/java/awt/print/PrinterJob/PrintTextPane.java
+++ b/jdk/test/java/awt/print/PrinterJob/PrintTextPane.java
@@ -21,15 +21,14 @@
* questions.
*/
-/**
- * @test PrintTextPane.java
- * @key headful printer
- * @bug 6452415 6570471
- * @summary Test that swing text prints using GDI printer fonts.
- * @author prr: area=PrinterJob
- * @run main PrintTextPane
- */
+/*
+ @test PrintTextPane.java
+ @bug 6452415 6570471
+ @summary Test that swing text prints using GDI printer fonts.
+ @author prr: area=PrinterJob
+ @run main PrintTextPane
+ */
import java.io.*;
import java.net.*;
import java.awt.*;
diff --git a/jdk/test/java/awt/print/PrinterJob/PrtException.java b/jdk/test/java/awt/print/PrinterJob/PrtException.java
index 152fe70d48..0387a3beb1 100644
--- a/jdk/test/java/awt/print/PrinterJob/PrtException.java
+++ b/jdk/test/java/awt/print/PrinterJob/PrtException.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -20,14 +20,12 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
- * @test
- * @key printer
- * @bug 4429544
- * @summary This test should not throw a printer exception. Test has been modified to correspond with the behavior of 1.5 and above.
- * @run main PrtException
- */
+/*
+ @test
+ @bug 4429544
+ @summary This test should not throw a printer exception. Test has been modified to correspond with the behavior of 1.5 and above.
+ @run main PrtException
+*/
import java.awt.*;
import java.awt.print.*;
diff --git a/jdk/test/java/net/CookieHandler/B6644726.java b/jdk/test/java/net/CookieHandler/B6644726.java
index cc31f64c1b..b1caa182d7 100644
--- a/jdk/test/java/net/CookieHandler/B6644726.java
+++ b/jdk/test/java/net/CookieHandler/B6644726.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2008, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2008, 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
@@ -46,8 +46,8 @@ public class B6644726 {
// Let's test the default path
lst.add("myCookie1=foo");
// Then some alternate expires format
- lst.add("myCookie2=bar; path=/dir; expires=Fri, 19 Aug 4242 16:00:00 GMT");
- lst.add("myCookie3=test; path=/dir; expires=Fri Aug 19 4242 16:00:00 GMT-0100");
+ lst.add("myCookie2=bar; path=/dir; expires=Tue, 19 Aug 2025 16:00:00 GMT");
+ lst.add("myCookie3=test; path=/dir; expires=Tue Aug 19 2025 16:00:00 GMT-0100");
// Then Netscape draft cookies and domains
lst.add("myCookie4=test; domain=.sun.com; path=/dir/foo");
HashMap<String, List<String>> map = new HashMap<String, List<String>>();
@@ -64,8 +64,7 @@ public class B6644726 {
List<HttpCookie> cookies = cs.getCookies();
// There should be 5 cookies if all dates parsed correctly
if (cookies.size() != 5) {
- fail("unexpected cookies: " + cookies + ", should have 5 cookies. Got only "
- + cookies.size() + ", expires probably didn't parse correctly");
+ fail("Should have 5 cookies. Got only "+ cookies.size() + ", expires probably didn't parse correctly");
}
// Check Path for first Cookie
for (HttpCookie c : cookies) {
diff --git a/jdk/test/java/net/Socket/B8312065.java b/jdk/test/java/net/Socket/B8312065.java
deleted file mode 100644
index 442e0c1fcd..0000000000
--- a/jdk/test/java/net/Socket/B8312065.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) 2023, Alibaba Group Holding Limited. 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 8312065
- * @summary Socket.connect does not timeout as expected when profiling (i.e. keep receiving signal)
- * @requires (os.family != "windows")
- * @build B8312065
- * @run shell B8312065.sh
- */
-
-import sun.misc.Signal;
-
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import java.net.SocketTimeoutException;
-import java.util.concurrent.TimeUnit;
-
-public class B8312065 {
- public static void main(String[] args) throws Exception {
- System.loadLibrary("NativeThread");
-
- // Setup SIGPIPE handler
- Signal.handle(new Signal("PIPE"), System.out::println);
-
- long osThreadId = NativeThread.getID();
-
- int timeoutMillis = 2000;
- int n = 10;
- Thread t = new Thread(() -> {
- // Send SIGPIPE to the thread every second
- for (int i = 0; i < n; i++) {
- if (NativeThread.signal(osThreadId, NativeThread.SIGPIPE) != 0) {
- System.out.println("Test FAILED: failed to send signal");
- System.exit(1);
- }
- try {
- Thread.sleep(1000);
- } catch (InterruptedException e) {
- System.out.println("Test FAILED: unexpected interrupt");
- System.exit(1);
- }
- }
- System.out.println("Test FAILED: Socket.connect blocked " + n + " seconds, " +
- "expected around " + timeoutMillis / 1000 + " seconds");
- System.exit(1);
- });
- t.setDaemon(true);
- t.start();
-
- long startTime = System.nanoTime();
-
- try {
- Socket socket = new Socket();
- // There is no good way to mock SocketTimeoutException, just assume 192.168.255.255 is not in use
- socket.connect(new InetSocketAddress("192.168.255.255", 8080), timeoutMillis);
- } catch (SocketTimeoutException e) {
- long duration = TimeUnit.MILLISECONDS.convert(System.nanoTime() - startTime, TimeUnit.NANOSECONDS);
- if (duration >= timeoutMillis) {
- System.out.println("Test passed");
- } else {
- System.out.println("Test FAILED: duration " + duration + " ms, expected >= " + timeoutMillis + " ms");
- System.exit(1);
- }
- }
- }
-}
diff --git a/jdk/test/java/net/Socket/B8312065.sh b/jdk/test/java/net/Socket/B8312065.sh
deleted file mode 100644
index d12596e5b6..0000000000
--- a/jdk/test/java/net/Socket/B8312065.sh
+++ /dev/null
@@ -1,46 +0,0 @@
-#!/bin/bash
-
-set -ex
-
-if [ "x$TESTGCC" = "x" ]; then
- TESTGCC=$(readlink -f $(which gcc))
-fi
-
-if [ "x$TESTGCC" = "x" ]; then
- echo "WARNING: gcc not found. Cannot execute test." 2>&1
- exit 1;
-fi
-
-if [ "x$TESTROOT" = "x" ]; then
- echo "TESTROOT pointintg to top level sources is not set. that is fatal"
- exit 2;
-fi
-
-if [ "x$TESTJAVA" = "x" ]; then
- TESTJAVA=$(dirname $(dirname $(readlink -f $(which java))))
-fi
-
-JDK_TOPDIR="${TESTROOT}/.."
-JAVA="${TESTJAVA}/bin/java"
-TEST_ENV_SH="${JDK_TOPDIR}/../hotspot/test/test_env.sh"
-
-ls -l "${TEST_ENV_SH}"
-set +e
- . "${TEST_ENV_SH}"
-set -e
-
-"${TESTGCC}" \
- -fPIC \
- -shared \
- ${CFLAGBITS} \
- -o ${TESTCLASSES}/libNativeThread.so \
- -I${JDK_TOPDIR}/src/share/bin \
- -I${JDK_TOPDIR}/src/share/javavm/export \
- -I${JDK_TOPDIR}/src/macosx/javavm/export \
- -I${JDK_TOPDIR}/src/solaris/bin \
- ${TESTSRC}/libNativeThread.c
-
-"${JAVA}" -Dtest.jdk=${TESTJAVA} \
- -Dtest.nativepath=${TESTCLASSES} \
- -Djava.library.path=${TESTCLASSES} \
- -cp ${TESTCLASSPATH}:${TESTCLASSES} B8312065
diff --git a/jdk/test/java/net/Socket/NativeThread.java b/jdk/test/java/net/Socket/NativeThread.java
deleted file mode 100644
index 5ab00ef855..0000000000
--- a/jdk/test/java/net/Socket/NativeThread.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2020, 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.
- */
-
-public class NativeThread {
-
- public static final int SIGPIPE;
-
- static {
- SIGPIPE = getSIGPIPE();
- }
-
- public static native long getID();
-
- public static native int signal(long threadId, int sig);
-
- private static native int getSIGPIPE();
-}
diff --git a/jdk/test/java/net/Socket/libNativeThread.c b/jdk/test/java/net/Socket/libNativeThread.c
deleted file mode 100644
index 8d2204cea7..0000000000
--- a/jdk/test/java/net/Socket/libNativeThread.c
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2020, 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.
- */
-#include<jni.h>
-#include<signal.h>
-#include<stdlib.h>
-#if defined(__linux__) || defined(_ALLBSD_SOURCE) || defined(_AIX)
-#include <pthread.h>
-#endif
-
-/*
- * Class: NativeThread
- * Method: getID
- * Signature: ()J
- */
-JNIEXPORT jlong JNICALL Java_NativeThread_getID(JNIEnv *env, jclass class)
-{
- #if defined(__linux__) || defined(_ALLBSD_SOURCE) || defined(_AIX)
- return (jlong)pthread_self();
- #else
- return 0;
- #endif
-}
-
-/*
- * Class: NativeThread
- * Method: signal
- * Signature: (JI)I
- */
-JNIEXPORT jint JNICALL Java_NativeThread_signal(JNIEnv *env, jclass class, jlong thread, jint sig)
-{
- #if defined(__linux__) || defined(_ALLBSD_SOURCE) || defined(_AIX)
- return pthread_kill((pthread_t)thread, sig);
- #else
- return 0;
- #endif
-}
-
-/*
- * Class: NativeThread
- * Method: getSIGPIPE
- * Signature: ()I
- */
-JNIEXPORT jint JNICALL Java_NativeThread_getSIGPIPE(JNIEnv *env, jclass class)
-{
- #if defined(__linux__) || defined(_ALLBSD_SOURCE) || defined(_AIX)
- return SIGPIPE;
- #else
- return 0;
- #endif
-}
diff --git a/jdk/test/java/security/testlibrary/CertificateBuilder.java b/jdk/test/java/security/testlibrary/CertificateBuilder.java
index b8cb1a73b4..4ab26d0d12 100644
--- a/jdk/test/java/security/testlibrary/CertificateBuilder.java
+++ b/jdk/test/java/security/testlibrary/CertificateBuilder.java
@@ -53,7 +53,6 @@ import sun.security.x509.SerialNumber;
import sun.security.x509.SubjectAlternativeNameExtension;
import sun.security.x509.URIName;
import sun.security.x509.KeyIdentifier;
-import sun.security.x509.X500Name;
/**
* Helper class that builds and signs X.509 certificates.
@@ -90,7 +89,7 @@ import sun.security.x509.X500Name;
public class CertificateBuilder {
private final CertificateFactory factory;
- private X500Name subjectName = null;
+ private X500Principal subjectName = null;
private BigInteger serialNumber = null;
private PublicKey publicKey = null;
private Date notBefore = null;
@@ -115,9 +114,8 @@ public class CertificateBuilder {
* @param name An {@link X500Principal} to be used as the subject name
* on this certificate.
*/
- public CertificateBuilder setSubjectName(X500Principal name) {
- subjectName = X500Name.asX500Name(name);
- return this;
+ public void setSubjectName(X500Principal name) {
+ subjectName = name;
}
/**
@@ -125,25 +123,8 @@ public class CertificateBuilder {
*
* @param name The subject name in RFC 2253 format
*/
- public CertificateBuilder setSubjectName(String name) {
- try {
- subjectName = new X500Name(name);
- } catch (IOException ioe) {
- throw new IllegalArgumentException(ioe);
- }
- return this;
- }
-
- /**
- * Set the subject name for the certificate. This method is useful when
- * you need more control over the contents of the subject name.
- *
- * @param name an {@code X500Name} to be used as the subject name
- * on this certificate
- */
- public CertificateBuilder setSubjectName(X500Name name) {
- subjectName = name;
- return this;
+ public void setSubjectName(String name) {
+ subjectName = new X500Principal(name);
}
/**
diff --git a/jdk/test/java/util/Currency/ISO4217-list-one.txt b/jdk/test/java/util/Currency/ISO4217-list-one.txt
index ca4bfd6dc9..1ad1fcb097 100644
--- a/jdk/test/java/util/Currency/ISO4217-list-one.txt
+++ b/jdk/test/java/util/Currency/ISO4217-list-one.txt
@@ -1,12 +1,12 @@
#
#
-# Amendments up until ISO 4217 AMENDMENT NUMBER 180
-# (As of 22 September 2025)
+# Amendments up until ISO 4217 AMENDMENT NUMBER 179
+# (As of 02 May 2025)
#
# Version
-FILEVERSION=3
-DATAVERSION=180
+FILEVERSION=2
+DATAVERSION=179
# ISO 4217 currency data
AF AFN 971 2
@@ -44,7 +44,7 @@ BV NOK 578 2
BR BRL 986 2
IO USD 840 2
BN BND 96 2
-BG BGN 975 2 2025-12-31-22-00-00 EUR 978 2
+BG BGN 975 2
BF XOF 952 0
BI BIF 108 0
KH KHR 116 2
@@ -69,7 +69,7 @@ CR CRC 188 2
CI XOF 952 0
HR EUR 978 2
CU CUP 192 2
-CW XCG 532 2
+CW ANG 532 2 2025-04-01-04-00-00 XCG 532 2
CY EUR 978 2
CZ CZK 203 2
DK DKK 208 2
@@ -233,7 +233,7 @@ LK LKR 144 2
SD SDG 938 2
SR SRD 968 2
SJ NOK 578 2
-SX XCG 532 2
+SX ANG 532 2 2025-04-01-04-00-00 XCG 532 2
SZ SZL 748 2
SE SEK 752 2
CH CHF 756 2
diff --git a/jdk/test/java/util/Currency/PropertiesTest.java b/jdk/test/java/util/Currency/PropertiesTest.java
index fe35f2e616..96127bf19f 100644
--- a/jdk/test/java/util/Currency/PropertiesTest.java
+++ b/jdk/test/java/util/Currency/PropertiesTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 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
@@ -25,7 +25,6 @@ import java.io.*;
import java.text.*;
import java.util.*;
import java.util.regex.*;
-import java.util.stream.Collectors;
public class PropertiesTest {
public static void main(String[] args) throws Exception {
@@ -33,14 +32,9 @@ public class PropertiesTest {
dump(args[1]);
} else if (args.length == 4 && args[0].equals("-c")) {
compare(args[1], args[2], args[3]);
- } else if (args.length == 1 && args[0].equals("bug7102969")) {
- bug7102969();
- } else if (args.length == 1 && args[0].equals("bug8157138")) {
- bug8157138();
} else {
System.err.println("Usage: java PropertiesTest -d <dumpfile>");
System.err.println(" java PropertiesTest -c <beforedump> <afterdump> <propsfile>");
- System.err.println(" java PropertiesTest bug[JBS bug id number] e.g. bug7102969");
System.exit(-1);
}
}
@@ -180,74 +174,6 @@ public class PropertiesTest {
}
}
- private static void bug7102969() {
-
- // check the correct overriding of special case entries
- Currency cur = Currency.getInstance(new Locale("", "JP"));
- if (!cur.getCurrencyCode().equals("ABC")) {
- throw new RuntimeException("[Expected: ABC as currency code of JP, found: "
- + cur.getCurrencyCode() + "]");
- }
-
- /* check if the currency instance is returned by
- * getAvailableCurrencies() method
- */
- if (!Currency.getAvailableCurrencies().contains(cur)) {
- throw new RuntimeException("[The Currency instance ["
- + cur.getCurrencyCode() + ", "
- + cur.getNumericCode() + ", "
- + cur.getDefaultFractionDigits()
- + "] is not available in the currencies list]");
- }
-
- }
-
- private static void bug8157138() {
-
- /* check the currencies which exist only as a special case are
- * accessible i.e. it should not throw IllegalArgumentException
- */
- try {
- Currency.getInstance("MAD");
- } catch (IllegalArgumentException ex) {
- throw new RuntimeException("Test Failed: "
- + "special case currency instance MAD not found"
- + " via Currency.getInstance(\"MAD\")");
- }
-
- try {
- Currency.getInstance("ABC");
- } catch (IllegalArgumentException ex) {
- throw new RuntimeException("Test Failed: "
- + "special case currency instance ABC not found"
- + " via Currency.getInstance(\"ABC\")");
- }
-
- /* check the currency value is returned by getAvailableCurrencies()
- * method
- */
- List<Currency> list = Currency.getAvailableCurrencies().stream()
- .filter(cur -> cur.getCurrencyCode().equals("MAD"))
- .collect(Collectors.toList());
-
- if (list.isEmpty()) {
- throw new RuntimeException("Test Failed: "
- + "special case currency instance MAD not found"
- + " in Currency.getAvailableCurrencies() list");
- }
-
- list = Currency.getAvailableCurrencies().stream()
- .filter(cur -> cur.getCurrencyCode().equals("ABC"))
- .collect(Collectors.toList());
-
- if (list.isEmpty()) {
- throw new RuntimeException("Test Failed: "
- + "special case currency instance ABC not found"
- + " in Currency.getAvailableCurrencies() list");
- }
-
- }
-
private static boolean isPastCutoverDate(String s)
throws IndexOutOfBoundsException, NullPointerException, ParseException {
String dateString = s.substring(s.lastIndexOf(',')+1, s.length()).trim();
diff --git a/jdk/test/java/util/Currency/PropertiesTest.sh b/jdk/test/java/util/Currency/PropertiesTest.sh
index 80fd1be06f..aa4f8d15b6 100644
--- a/jdk/test/java/util/Currency/PropertiesTest.sh
+++ b/jdk/test/java/util/Currency/PropertiesTest.sh
@@ -23,7 +23,7 @@
#
# @test
-# @bug 6332666 6863624 7180362 8003846 8074350 8074351 7102969 8157138
+# @bug 6332666 6863624 7180362 8003846 8074350 8074351
# @summary tests the capability of replacing the currency data with user
# specified currency properties file
# @build PropertiesTest
@@ -124,16 +124,6 @@ echo ''
sh -xc "${WRITABLEJDK}${FS}bin${FS}java ${TESTVMOPTS} -cp ${TESTCLASSES} PropertiesTest -d dump3"
if [ $? != 0 ]; then failures=`expr $failures + 1`; fi
-# run bug7102969 test
-echo ''
-${WRITABLEJDK}${FS}bin${FS}java ${TESTVMOPTS} -cp ${TESTCLASSES} PropertiesTest bug7102969
-if [ $? != 0 ]; then failures=`expr $failures + 1`; fi
-
-# run bug8157138 test
-echo ''
-${WRITABLEJDK}${FS}bin${FS}java ${TESTVMOPTS} -cp ${TESTCLASSES} PropertiesTest bug8157138
-if [ $? != 0 ]; then failures=`expr $failures + 1`; fi
-
# Cleanup
rm -f ${PROPLOCATION}${FS}currency.properties
if [ $COPIED -eq 1 ]
diff --git a/jdk/test/java/util/Currency/ValidateISO4217.java b/jdk/test/java/util/Currency/ValidateISO4217.java
index 9e49a44f9e..50ef6c15d4 100644
--- a/jdk/test/java/util/Currency/ValidateISO4217.java
+++ b/jdk/test/java/util/Currency/ValidateISO4217.java
@@ -25,7 +25,7 @@
* @bug 4691089 4819436 4942982 5104960 6544471 6627549 7066203 7195759
* 8074350 8074351 8145952 8187946 8193552 8202026 8204269
* 8208746 8209775 8274658 8283277 8296239 8321480 8334653
- * 8356096 8368308
+ * 8356096
* @summary Validate ISO 4217 data for Currency class.
*/
@@ -95,7 +95,7 @@ public class ValidateISO4217 {
/* Codes that are obsolete, do not have related country, extra currency */
static final String otherCodes =
- "ADP-AFA-ATS-AYM-AZM-BEF-BGL-BGN-BOV-BYB-BYR-CHE-CHW-CLF-COU-CUC-CYP-"
+ "ADP-AFA-ATS-AYM-AZM-BEF-BGL-BOV-BYB-BYR-CHE-CHW-CLF-COU-CUC-CYP-"
+ "DEM-EEK-ESP-FIM-FRF-GHC-GRD-GWP-HRK-IEP-ITL-LTL-LUF-LVL-MGF-MRO-MTL-MXV-MZM-NLG-"
+ "PTE-ROL-RUR-SDD-SIT-SLL-SKK-SRG-STD-TMM-TPE-TRL-VEF-UYI-USN-USS-VEB-VED-"
+ "XAD-XAG-XAU-XBA-XBB-XBC-XBD-XDR-XFO-XFU-XPD-XPT-XSU-XTS-XUA-XXX-"
diff --git a/jdk/test/java/util/Currency/currency.properties b/jdk/test/java/util/Currency/currency.properties
index 57b293542b..d8e874d819 100644
--- a/jdk/test/java/util/Currency/currency.properties
+++ b/jdk/test/java/util/Currency/currency.properties
@@ -6,7 +6,7 @@
CL=CLF,990,4
CM=IED,111,2, 2004-01-01T00:70:00
ES=ESD,877,2
-JP=ABC,999,0
+JP=JPZ,123,2
MA=MAA,555,5
MC=MCC,555,6
MD=MDD,555,7
diff --git a/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java b/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java
index 9430813d02..b0a1ecc8be 100644
--- a/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java
+++ b/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java
@@ -120,8 +120,7 @@ public class ConcurrentAssociateTest {
}
};
- // Bound concurrency to avoid degenerate performance
- int ps = Math.min(Runtime.getRuntime().availableProcessors(), 32);
+ int ps = Runtime.getRuntime().availableProcessors();
Stream<CompletableFuture> runners = IntStream.range(0, ps)
.mapToObj(i -> sr.get())
.map(CompletableFuture::runAsync);
diff --git a/jdk/test/javax/print/CheckDupFlavor.java b/jdk/test/javax/print/CheckDupFlavor.java
index 4e1bfd9cef..6507ab2f07 100644
--- a/jdk/test/javax/print/CheckDupFlavor.java
+++ b/jdk/test/javax/print/CheckDupFlavor.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2004, 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,14 +21,12 @@
* questions.
*/
-/**
+/*
* @test
- * @key printer
* @bug 4996318 6731937
* @summary There should be no duplicates returned by getSupportedDocFlavors.
* @run main CheckDupFlavor
*/
-
import javax.print.*;
import javax.print.attribute.*;
import javax.print.attribute.standard.*;
diff --git a/jdk/test/javax/print/PrintSE/PrintSE.sh b/jdk/test/javax/print/PrintSE/PrintSE.sh
index d4b3adabe4..9b555054f0 100644
--- a/jdk/test/javax/print/PrintSE/PrintSE.sh
+++ b/jdk/test/javax/print/PrintSE/PrintSE.sh
@@ -1,7 +1,7 @@
#!/bin/sh
#
-# Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
@@ -24,11 +24,8 @@
#
# @test
-# @key printer
# @bug 6662775
-# @summary Tests queuePrintJob is sufficient permission for printing. This test
-# prints a page to a printer. If a document printer is installed, a
-# popup can appear (to select the file location).
+# @summary Tests queuePrintJob is sufficient permission.
# @run clean PrintSE
# @run build PrintSE
# @run compile PrintSE.java
diff --git a/jdk/test/javax/print/attribute/AttributeTest.java b/jdk/test/javax/print/attribute/AttributeTest.java
index e87ae44d77..1bd23f8358 100644
--- a/jdk/test/javax/print/attribute/AttributeTest.java
+++ b/jdk/test/javax/print/attribute/AttributeTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,14 +21,12 @@
* questions.
*/
-/**
+/*
* @test
- * @key printer
* @bug 6387255
* @summary Tests conflict of Media values returned by isAttrValueSupported and getSupportedAttrValues. No runtime exception should be thrown.
* @run main AttributeTest
*/
-
import javax.print.*;
import javax.print.attribute.standard.*;
import javax.print.attribute.*;
diff --git a/jdk/test/javax/print/attribute/GetCopiesSupported.java b/jdk/test/javax/print/attribute/GetCopiesSupported.java
index 8a4080565f..ea366729f9 100644
--- a/jdk/test/javax/print/attribute/GetCopiesSupported.java
+++ b/jdk/test/javax/print/attribute/GetCopiesSupported.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -20,14 +20,12 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
- * @test
- * @key printer
- * @bug 4463280
- * @summary No ClassCastException should occur.
- * @run main GetCopiesSupported
- */
+/*
+ @test
+ @bug 4463280
+ @summary No ClassCastException should occur.
+ @run main GetCopiesSupported
+*/
import javax.print.*;
import javax.print.attribute.*;
diff --git a/jdk/test/javax/print/attribute/SidesPageRangesTest.java b/jdk/test/javax/print/attribute/SidesPageRangesTest.java
index 476a6cf1f4..a5092cdfde 100644
--- a/jdk/test/javax/print/attribute/SidesPageRangesTest.java
+++ b/jdk/test/javax/print/attribute/SidesPageRangesTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -20,15 +20,12 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
+/*
* @test
- * @key printer
* @bug 4903366
* @summary No crash should occur.
* @run main SidesPageRangesTest
- */
-
+*/
import java.awt.*;
import javax.print.*;
import javax.print.attribute.standard.*;
diff --git a/jdk/test/javax/print/attribute/SupportedPrintableAreas.java b/jdk/test/javax/print/attribute/SupportedPrintableAreas.java
index 84700c671d..9ae66db407 100644
--- a/jdk/test/javax/print/attribute/SupportedPrintableAreas.java
+++ b/jdk/test/javax/print/attribute/SupportedPrintableAreas.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key printer
* @bug 4762773 6289206 6324049 6362765
* @summary Tests that get non-null return list of printable areas.
* @run main SupportedPrintableAreas
diff --git a/jdk/test/javax/swing/JComboBox/8019180/Test8019180.java b/jdk/test/javax/swing/JComboBox/8019180/Test8019180.java
index 766400e3ba..d089f998eb 100644
--- a/jdk/test/javax/swing/JComboBox/8019180/Test8019180.java
+++ b/jdk/test/javax/swing/JComboBox/8019180/Test8019180.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -26,9 +26,8 @@ import javax.swing.JComboBox;
import javax.swing.JFrame;
import javax.swing.SwingUtilities;
-/**
+/*
* @test
- * @key headful
* @bug 8019180
* @summary Tests that combobox works if it is used as action listener
* @author Sergey Malenkov
diff --git a/jdk/test/javax/swing/JComponent/4337267/bug4337267.java b/jdk/test/javax/swing/JComponent/4337267/bug4337267.java
index 83a08f87b6..1c316f8597 100644
--- a/jdk/test/javax/swing/JComponent/4337267/bug4337267.java
+++ b/jdk/test/javax/swing/JComponent/4337267/bug4337267.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 4337267
* @summary test that numeric shaping works in Swing components
* @author Sergey Groznyh
diff --git a/jdk/test/javax/swing/JComponent/8043610/bug8043610.java b/jdk/test/javax/swing/JComponent/8043610/bug8043610.java
index d559e05411..b4fc89f055 100644
--- a/jdk/test/javax/swing/JComponent/8043610/bug8043610.java
+++ b/jdk/test/javax/swing/JComponent/8043610/bug8043610.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -22,15 +22,13 @@
*/
-/**
- * @test
- * @key headful
- * @bug 8043610
- * @summary Tests that JComponent invalidate, revalidate and repaint methods could
- * be called from any thread
- * @author Petr Pchelko
- */
-
+/*
+ @test
+ @bug 8043610
+ @summary Tests that JComponent invalidate, revalidate and repaint methods could
+ be called from any thread
+ @author Petr Pchelko
+*/
import sun.awt.SunToolkit;
diff --git a/jdk/test/javax/swing/JDialog/6639507/bug6639507.java b/jdk/test/javax/swing/JDialog/6639507/bug6639507.java
index 5c24c17a39..13d1915a3b 100644
--- a/jdk/test/javax/swing/JDialog/6639507/bug6639507.java
+++ b/jdk/test/javax/swing/JDialog/6639507/bug6639507.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,14 +21,11 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6639507
- * @summary Title of javax.swing.JDialog is null while spec says it's empty
- * @author Pavel Porvatov
- */
-
+/* @test
+ @bug 6639507
+ @summary Title of javax.swing.JDialog is null while spec says it's empty
+ @author Pavel Porvatov
+*/
import javax.swing.*;
import java.awt.*;
diff --git a/jdk/test/javax/swing/JFileChooser/6713352/bug6713352.java b/jdk/test/javax/swing/JFileChooser/6713352/bug6713352.java
index a4cb739d94..6ec2e4fffc 100644
--- a/jdk/test/javax/swing/JFileChooser/6713352/bug6713352.java
+++ b/jdk/test/javax/swing/JFileChooser/6713352/bug6713352.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,14 +21,12 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6713352
- * @summary Deadlock in JFileChooser with synchronized custom FileSystemView
- * @author Pavel Porvatov
- * @run main bug6713352
- */
+/* @test
+ @bug 6713352
+ @summary Deadlock in JFileChooser with synchronized custom FileSystemView
+ @author Pavel Porvatov
+ @run main bug6713352
+*/
import sun.awt.shell.ShellFolder;
diff --git a/jdk/test/javax/swing/JFileChooser/6817933/Test6817933.java b/jdk/test/javax/swing/JFileChooser/6817933/Test6817933.java
index 09b8f25fc2..2b65f173a1 100644
--- a/jdk/test/javax/swing/JFileChooser/6817933/Test6817933.java
+++ b/jdk/test/javax/swing/JFileChooser/6817933/Test6817933.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,13 +21,11 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 6817933
* @summary Tests that HTMLEditorKit does not affect JFileChooser
* @author Sergey Malenkov
- * @requires (os.family == "windows")
*/
import java.awt.Color;
diff --git a/jdk/test/javax/swing/JFileChooser/8013442/Test8013442.java b/jdk/test/javax/swing/JFileChooser/8013442/Test8013442.java
index 7232a3ce37..e7b892ddae 100644
--- a/jdk/test/javax/swing/JFileChooser/8013442/Test8013442.java
+++ b/jdk/test/javax/swing/JFileChooser/8013442/Test8013442.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8013442
* @summary Tests that at least one file filter is selected
* @author Sergey Malenkov
diff --git a/jdk/test/javax/swing/JFrame/8016356/bug8016356.java b/jdk/test/javax/swing/JFrame/8016356/bug8016356.java
index 7954c2a752..b5ee38ef3e 100644
--- a/jdk/test/javax/swing/JFrame/8016356/bug8016356.java
+++ b/jdk/test/javax/swing/JFrame/8016356/bug8016356.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -21,15 +21,12 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 8016356
- * @summary Any swing frame resizes ugly.
- * @author Oleg Pekhovskiy
- * @requires (os.family == "windows")
- * @run main bug8016356
- */
+/* @test
+ @bug 8016356
+ @summary Any swing frame resizes ugly.
+ @run main bug8016356
+ @author Oleg Pekhovskiy
+*/
import java.awt.AWTException;
import java.awt.Color;
diff --git a/jdk/test/javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java b/jdk/test/javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java
index 8f1ccad851..8b5f06c915 100644
--- a/jdk/test/javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java
+++ b/jdk/test/javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -32,7 +32,6 @@ import jdk.testlibrary.OSInfo;
/**
* @test
- * @key headful
* @bug 7124513
* @summary We should support NSTexturedBackgroundWindowMask style on OSX.
* @author Sergey Bylokhov
@@ -40,7 +39,6 @@ import jdk.testlibrary.OSInfo;
* @build ExtendedRobot jdk.testlibrary.OSInfo
* @run main NSTexturedJFrame
*/
-
public final class NSTexturedJFrame {
private static final String BRUSH = "apple.awt.brushMetalLook";
diff --git a/jdk/test/javax/swing/JInternalFrame/Test6325652.java b/jdk/test/javax/swing/JInternalFrame/Test6325652.java
index dd3a2d99eb..ad82ade452 100644
--- a/jdk/test/javax/swing/JInternalFrame/Test6325652.java
+++ b/jdk/test/javax/swing/JInternalFrame/Test6325652.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 6325652
* @summary Tests keyboard shortcuts
* @author Sergey Malenkov
diff --git a/jdk/test/javax/swing/JMenu/6538132/bug6538132.java b/jdk/test/javax/swing/JMenu/6538132/bug6538132.java
index 3d2101e1b8..73a61eaa6c 100644
--- a/jdk/test/javax/swing/JMenu/6538132/bug6538132.java
+++ b/jdk/test/javax/swing/JMenu/6538132/bug6538132.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2014, 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
@@ -20,18 +20,14 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
- * @test
- * @key headful
- * @bug 6538132
- * @summary Regression: Pressing Escape key don't close the menu items from jdk7.0 b07 onwards
- * @author Alexander Potochkin
- * @requires (os.family == "windows")
- * @library ../../../../lib/testlibrary
- * @build ExtendedRobot
- * @run main bug6538132
- */
+/* @test
+ @bug 6538132
+ @summary Regression: Pressing Escape key don't close the menu items from jdk7.0 b07 onwards
+ @author Alexander Potochkin
+ @library ../../../../lib/testlibrary
+ @build ExtendedRobot
+ @run main bug6538132
+*/
import javax.swing.*;
import java.awt.*;
diff --git a/jdk/test/javax/swing/JMenuItem/8152981/MenuItemIconTest.java b/jdk/test/javax/swing/JMenuItem/8152981/MenuItemIconTest.java
index 21c135f327..451da3cec4 100644
--- a/jdk/test/javax/swing/JMenuItem/8152981/MenuItemIconTest.java
+++ b/jdk/test/javax/swing/JMenuItem/8152981/MenuItemIconTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 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
@@ -21,15 +21,13 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8152981 8159135
* @summary Double icons with JMenuItem setHorizontalTextPosition on Win 10
* @requires (os.family == "windows")
* @run main MenuItemIconTest
*/
-
import java.awt.Color;
import java.awt.Dimension;
import java.awt.Graphics;
diff --git a/jdk/test/javax/swing/JMenuItem/ActionListenerCalledTwice/ActionListenerCalledTwiceTest.java b/jdk/test/javax/swing/JMenuItem/ActionListenerCalledTwice/ActionListenerCalledTwiceTest.java
index f9bf845515..1a9f42120e 100644
--- a/jdk/test/javax/swing/JMenuItem/ActionListenerCalledTwice/ActionListenerCalledTwiceTest.java
+++ b/jdk/test/javax/swing/JMenuItem/ActionListenerCalledTwice/ActionListenerCalledTwiceTest.java
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 7160951
* @summary [macosx] ActionListener called twice for JMenuItem using ScreenMenuBar
* @author [email protected]
diff --git a/jdk/test/javax/swing/JMenuItem/TestRadioAndCheckMenuItemWithIcon.java b/jdk/test/javax/swing/JMenuItem/TestRadioAndCheckMenuItemWithIcon.java
deleted file mode 100644
index 7fa7e5dd0a..0000000000
--- a/jdk/test/javax/swing/JMenuItem/TestRadioAndCheckMenuItemWithIcon.java
+++ /dev/null
@@ -1,228 +0,0 @@
-/*
- * Copyright (c) 2025, 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 8348760
- * @summary Verify if RadioButtonMenuItem bullet and
- * JCheckboxMenuItem checkmark is shown if
- * JRadioButtonMenuItem and JCheckboxMenuItem
- * is rendered with ImageIcon in WindowsLookAndFeel
- * @requires (os.family == "windows")
- * @run main/manual TestRadioAndCheckMenuItemWithIcon
- */
-
-import java.awt.BorderLayout;
-import java.awt.Color;
-import java.awt.FlowLayout;
-import java.awt.Graphics;
-import java.awt.GridLayout;
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.awt.event.KeyEvent;
-import java.awt.event.WindowAdapter;
-import java.awt.event.WindowEvent;
-import java.awt.image.BufferedImage;
-import java.util.concurrent.LinkedBlockingQueue;
-
-import javax.swing.AbstractButton;
-import javax.swing.ButtonGroup;
-import javax.swing.ImageIcon;
-import javax.swing.JButton;
-import javax.swing.JCheckBoxMenuItem;
-import javax.swing.JFrame;
-import javax.swing.JMenu;
-import javax.swing.JMenuBar;
-import javax.swing.JMenuItem;
-import javax.swing.JPanel;
-import javax.swing.JRadioButtonMenuItem;
-import javax.swing.JScrollPane;
-import javax.swing.JTextArea;
-import javax.swing.KeyStroke;
-import javax.swing.SwingUtilities;
-import javax.swing.UIManager;
-
-public class TestRadioAndCheckMenuItemWithIcon {
-
- private static final String INSTRUCTIONS =
- "Clicking on the Menu above will show a\n"
- + "JRadioButtonMenuItem group with 3 radiobutton menuitems\n"
- + "and a JCheckBoxMenuItem group with 3 checkbox menuitems.\n"
- + "\n"
- + "First radiobutton menuitem is selected with imageicon of a red square.\n"
- + "Second radiobutton menuitem is unselected with imageicon.\n"
- + "Third radiobutton menuItem is unselected without imageicon.\n"
- + "\n"
- + "First checkbox menuitem is selected with imageicon.\n"
- + "Second checkbox menuitem is unselected with imageicon.\n"
- + "Third checkbox menuItem is unselected without imageicon.\n"
- + "\n"
- + "Verify that for first JRadioButtonMenuItem with imageicon,\n"
- + "a bullet is shown alongside the imageicon and\n"
- + "for first JCheckBoxMenuItem with imageicon\n"
- + "a checkmark is shown alongside the imageicon.\n"
- + "\n"
- + "If bullet and checkmark is shown, test passes else fails.";
-
- private static final LinkedBlockingQueue<Boolean> resultQueue = new LinkedBlockingQueue<Boolean>(1);
-
- private static void endTest(boolean result) {
- SwingUtilities.invokeLater(
- new Runnable() {
- public void run() {
- try {
- resultQueue.put(result);
- } catch (Exception ignored) {
- }
- }
- });
- }
-
- public static void main(String[] args) throws Exception {
- UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
-
- SwingUtilities.invokeLater(new Runnable() {
- public void run() {
- TestRadioAndCheckMenuItemWithIcon.doTest();
- }
- });
-
- Boolean testPasses = resultQueue.take();
-
- if (!testPasses) {
- throw new Exception("Test failed!");
- }
- }
-
- public static void doTest() {
- BufferedImage img = new BufferedImage(16, 16, BufferedImage.TYPE_INT_ARGB);
- Graphics g = img.getGraphics();
- g.setColor(Color.red);
- g.fillRect(0, 0, img.getWidth(), img.getHeight());
- g.dispose();
-
- BufferedImage img2 = new BufferedImage(64, 64, BufferedImage.TYPE_INT_ARGB);
- Graphics g2 = img2.getGraphics();
- g2.setColor(Color.red);
- g2.fillRect(0, 0, img2.getWidth(), img2.getHeight());
- g2.dispose();
-
- JFrame frame = new JFrame("RadioButtonWithImageIcon");
- ImageIcon imageIcon1 = new ImageIcon(img);
- ImageIcon imageIcon2 = new ImageIcon(img2);
- AbstractButton button1;
- JRadioButtonMenuItem m1 = new JRadioButtonMenuItem("JRadioButtonMenuItem 1",
- imageIcon1);
- m1.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_F4, ActionEvent.ALT_MASK|ActionEvent.CTRL_MASK|ActionEvent.SHIFT_MASK));
- button1 = m1;
- button1.setSelected(true);
- AbstractButton button2 = new JRadioButtonMenuItem("JRadioButtonMenuItem 2", imageIcon2);
- AbstractButton button3 = new JRadioButtonMenuItem("JRadioButtonMenuItem 3");
-
- ButtonGroup buttonGroup = new ButtonGroup();
- buttonGroup.add(button1);
- buttonGroup.add(button2);
- buttonGroup.add(button3);
-
- AbstractButton check1 = new JCheckBoxMenuItem("JCheckBoxMenuItem 1",
- imageIcon1);
- check1.setSelected(true);
- AbstractButton check2 = new JCheckBoxMenuItem("JCheckBoxMenuItem 2", imageIcon1);
- JCheckBoxMenuItem c3;
- AbstractButton check3 = c3 = new JCheckBoxMenuItem("JCheckBoxMenuItem 3");
- c3.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_F5, ActionEvent.ALT_MASK|ActionEvent.CTRL_MASK|ActionEvent.SHIFT_MASK));
-
- JMenu topLevel = new JMenu("Menu");
-
- topLevel.add(button1);
- topLevel.add(button2);
- topLevel.add(button3);
-
- topLevel.addSeparator();
-
- topLevel.add(check1);
- topLevel.add(check2);
- topLevel.add(check3);
-
- AbstractButton menuitem1 = new JMenuItem("MenuItem1");
- AbstractButton menuitem2 = new JMenuItem("MenuItem2", imageIcon1);
- topLevel.addSeparator();
- topLevel.add(menuitem1);
- topLevel.add(menuitem2);
-
- JMenuBar menuBar = new JMenuBar();
- menuBar.add(topLevel);
-
- frame.setJMenuBar(menuBar);
-
- JTextArea instructions = new JTextArea();
- instructions.setText(INSTRUCTIONS);
- instructions.setEditable(false);
- instructions.setColumns(80);
- instructions.setRows(24);
-
- JScrollPane scrInstructions = new JScrollPane(instructions);
- frame.getContentPane().setLayout(new BorderLayout());
-
- frame.getContentPane().add(scrInstructions, BorderLayout.CENTER);
-
- JPanel yesno = new JPanel();
- yesno.setLayout(new GridLayout(1, 2, 40, 40));
-
- JButton yes = new JButton("Passes");
- JButton no = new JButton("Fails");
- yesno.add(yes);
- yesno.add(no);
-
- yes.addActionListener(new ActionListener() {
- @Override
- public void actionPerformed(ActionEvent e) {
- frame.dispose();
- endTest(true);
- }
- });
-
- no.addActionListener(new ActionListener() {
- @Override
- public void actionPerformed(ActionEvent e) {
- frame.dispose();
- endTest(false);
- }
- });
-
- frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
- frame.addWindowListener(new WindowAdapter() {
- @Override
- public void windowClosed(WindowEvent e) {
- frame.dispose();
- endTest(false);
- }
- });
-
- frame.getContentPane().add(yesno, BorderLayout.SOUTH);
-
- frame.pack();
- frame.setLocationRelativeTo(null);
- frame.setVisible(true);
- }
-}
diff --git a/jdk/test/javax/swing/JPopupMenu/6217905/bug6217905.java b/jdk/test/javax/swing/JPopupMenu/6217905/bug6217905.java
index 8f9b7b6b2a..dcfab1da77 100644
--- a/jdk/test/javax/swing/JPopupMenu/6217905/bug6217905.java
+++ b/jdk/test/javax/swing/JPopupMenu/6217905/bug6217905.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2014, 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
@@ -20,18 +20,15 @@
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-
-/**
- * @test
- * @key headful
- * @bug 6217905
- * @summary JPopupMenu keyboard navigation stops working
- * @author Alexander Potochkin
- * @requires (os.family == "windows")
- * @library ../../../../lib/testlibrary
- * @build ExtendedRobot
- * @run main bug6217905
- */
+/*
+@test
+@bug 6217905
+@summary JPopupMenu keyboard navigation stops working
+@author Alexander Potochkin
+@library ../../../../lib/testlibrary
+@build ExtendedRobot
+@run main bug6217905
+*/
import javax.swing.*;
import java.awt.*;
diff --git a/jdk/test/javax/swing/JPopupMenu/7154841/bug7154841.java b/jdk/test/javax/swing/JPopupMenu/7154841/bug7154841.java
index 0e0a8cfe39..e2369914a7 100644
--- a/jdk/test/javax/swing/JPopupMenu/7154841/bug7154841.java
+++ b/jdk/test/javax/swing/JPopupMenu/7154841/bug7154841.java
@@ -21,15 +21,14 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 7154841
- * @summary JPopupMenu is overlapped by a Dock on Mac OS X
- * @author Petr Pchelko
- * @library ../../../../lib/testlibrary
- * @build ExtendedRobot jdk.testlibrary.OSInfo
- * @run main bug7154841
+/*
+ @test
+ @bug 7154841
+ @summary JPopupMenu is overlapped by a Dock on Mac OS X
+ @author Petr Pchelko
+ @library ../../../../lib/testlibrary
+ @build ExtendedRobot jdk.testlibrary.OSInfo
+ @run main bug7154841
*/
import java.awt.*;
diff --git a/jdk/test/javax/swing/JTabbedPane/7170310/bug7170310.java b/jdk/test/javax/swing/JTabbedPane/7170310/bug7170310.java
index 0c045ca33e..94eaa6e3ce 100644
--- a/jdk/test/javax/swing/JTabbedPane/7170310/bug7170310.java
+++ b/jdk/test/javax/swing/JTabbedPane/7170310/bug7170310.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 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
@@ -37,7 +37,6 @@ import javax.swing.plaf.metal.MetalLookAndFeel;
/**
* @test
- * @key headful
* @bug 7170310
* @author Alexey Ivanov
* @summary Selected tab should be scrolled into view.
@@ -45,7 +44,6 @@ import javax.swing.plaf.metal.MetalLookAndFeel;
* @build ExtendedRobot
* @run main bug7170310
*/
-
public class bug7170310 {
private static final int TABS_NUMBER = 3;
@@ -77,7 +75,7 @@ public class bug7170310 {
System.out.printf("Test passed");
}
} finally {
- if (frame != null) { frame.dispose(); }
+ frame.dispose();
}
}
diff --git a/jdk/test/javax/swing/JTextArea/6940863/bug6940863.java b/jdk/test/javax/swing/JTextArea/6940863/bug6940863.java
index 5f70d4280c..b868d41adf 100644
--- a/jdk/test/javax/swing/JTextArea/6940863/bug6940863.java
+++ b/jdk/test/javax/swing/JTextArea/6940863/bug6940863.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,13 +21,10 @@
* questions.
*/
-/**
- * @test
- * @key headful
+/* @test
* @bug 6940863
* @summary Textarea within scrollpane shows vertical scrollbar
* @author Pavel Porvatov
- * @requires (os.family == "windows")
* @run main bug6940863
*/
diff --git a/jdk/test/javax/swing/Security/6938813/bug6938813.java b/jdk/test/javax/swing/Security/6938813/bug6938813.java
index ab6121f095..5bedf95e14 100644
--- a/jdk/test/javax/swing/Security/6938813/bug6938813.java
+++ b/jdk/test/javax/swing/Security/6938813/bug6938813.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/*
* @test
- * @key headful
* @bug 6938813
* @summary Swing mutable statics
* @author Pavel Porvatov
diff --git a/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java b/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java
index 9057e3a39b..549f9ec57e 100644
--- a/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java
+++ b/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java
@@ -21,27 +21,27 @@
* questions.
*/
-/**
- * @test
- * @bug 7123767
- *
- * @summary Check if a tooltip location in Multi-Monitor
- * configurations is correct.
- * If the configurations number per device exceeds 5,
- * then some 5 random configurations will be checked.
- * Please Use -Dseed=X to set the random generator seed
- * (if necessary).
- *
- * @author Vladislav Karnaukhov
- *
- * @key headful randomness
- *
- * @modules java.desktop/sun.awt
- * @library /lib/testlibrary/
- * @build jdk.testlibrary.*
- *
- * @run main/timeout=300 bug7123767
- */
+/* @test
+* @bug 7123767
+*
+* @summary Check if a tooltip location in Multi-Monitor
+* configurations is correct.
+* If the configurations number per device exceeds 5,
+* then some 5 random configurations will be checked.
+* Please Use -Dseed=X to set the random generator seed
+* (if necessary).
+*
+* @author Vladislav Karnaukhov
+*
+* @key headful
+* @key randomness
+*
+* @modules java.desktop/sun.awt
+* @library /lib/testlibrary/
+* @build jdk.testlibrary.*
+*
+* @run main/timeout=300 bug7123767
+*/
import javax.swing.*;
import javax.swing.plaf.metal.MetalLookAndFeel;
diff --git a/jdk/test/javax/swing/plaf/aqua/CustomComboBoxFocusTest.java b/jdk/test/javax/swing/plaf/aqua/CustomComboBoxFocusTest.java
index 29b62136fe..0c28983560 100644
--- a/jdk/test/javax/swing/plaf/aqua/CustomComboBoxFocusTest.java
+++ b/jdk/test/javax/swing/plaf/aqua/CustomComboBoxFocusTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,16 +21,14 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 8073001 8081764
- * @summary Test verifies that combo box with custom editor renders
- * focus ring around arrow button correctly.
- * @library /lib/testlibrary
- * @build jdk.testlibrary.OSInfo
- * @run main CustomComboBoxFocusTest
- */
+/* @test
+ @bug 8073001 8081764
+ @summary Test verifies that combo box with custom editor renders
+ focus ring around arrow button correctly.
+ @library /lib/testlibrary
+ @build jdk.testlibrary.OSInfo
+ @run main CustomComboBoxFocusTest
+*/
import java.awt.AWTException;
import java.awt.Component;
diff --git a/jdk/test/javax/swing/plaf/basic/BasicComboPopup/8154069/Bug8154069.java b/jdk/test/javax/swing/plaf/basic/BasicComboPopup/8154069/Bug8154069.java
index 2e60bf3838..35250a5870 100644
--- a/jdk/test/javax/swing/plaf/basic/BasicComboPopup/8154069/Bug8154069.java
+++ b/jdk/test/javax/swing/plaf/basic/BasicComboPopup/8154069/Bug8154069.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -23,7 +23,6 @@
/*
* @test
- * @key headful
* @bug 8154069
* @summary Jaws reads wrong values from comboboxes when no element is selected
* @run main Bug8154069
@@ -90,7 +89,7 @@ public class Bug8154069 {
}
} finally {
SwingUtilities.invokeAndWait(() -> {
- if (frame != null) { frame.dispose(); }
+ frame.dispose();
});
}
}
diff --git a/jdk/test/javax/swing/plaf/basic/BasicHTML/4960629/bug4960629.java b/jdk/test/javax/swing/plaf/basic/BasicHTML/4960629/bug4960629.java
index 5b7ff84fe7..1e02204c4f 100644
--- a/jdk/test/javax/swing/plaf/basic/BasicHTML/4960629/bug4960629.java
+++ b/jdk/test/javax/swing/plaf/basic/BasicHTML/4960629/bug4960629.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,14 +21,12 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 4960629 7124238
- * @summary Tests if font for html text on widgets in correct.
- * @author Denis Sharypov
- * @run main bug4960629
- */
+/* @test
+ @bug 4960629 7124238
+ @summary Tests if font for html text on widgets in correct.
+ @author Denis Sharypov
+ @run main bug4960629
+*/
import java.awt.Font;
import java.lang.reflect.InvocationTargetException;
@@ -59,7 +57,7 @@ public class bug4960629 {
f.setVisible(true);
test();
} finally {
- if (f != null) { f.dispose(); }
+ f.dispose();
}
}
diff --git a/jdk/test/javax/swing/plaf/basic/BasicLabelUI/bug7172652.java b/jdk/test/javax/swing/plaf/basic/BasicLabelUI/bug7172652.java
index 7fcbc5e78d..8a06c48e90 100644
--- a/jdk/test/javax/swing/plaf/basic/BasicLabelUI/bug7172652.java
+++ b/jdk/test/javax/swing/plaf/basic/BasicLabelUI/bug7172652.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,17 +21,14 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 7172652
- * @summary With JDK 1.7 text field does not obtain focus when using mnemonic Alt/Key combin
- * @author Semyon Sadetsky
- * @requires (os.family == "windows")
- * @library /lib/testlibrary
- * @build jdk.testlibrary.OSInfo
- * @run main bug7172652
- */
+/* @test
+ @bug 7172652
+ @summary With JDK 1.7 text field does not obtain focus when using mnemonic Alt/Key combin
+ @author Semyon Sadetsky
+ @library /lib/testlibrary
+ @build jdk.testlibrary.OSInfo
+ @run main bug7172652
+ */
import javax.swing.*;
import javax.swing.event.ChangeEvent;
diff --git a/jdk/test/javax/swing/plaf/nimbus/8041642/ScrollBarThumbVisibleTest.java b/jdk/test/javax/swing/plaf/nimbus/8041642/ScrollBarThumbVisibleTest.java
index 59fe7cb4fc..4d147ac8bd 100644
--- a/jdk/test/javax/swing/plaf/nimbus/8041642/ScrollBarThumbVisibleTest.java
+++ b/jdk/test/javax/swing/plaf/nimbus/8041642/ScrollBarThumbVisibleTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -21,13 +21,11 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 8134828
- * @summary Scrollbar thumb disappears with Nimbus L&F
- * @author Semyon Sadetsky
- */
+/* @test
+ @bug 8134828
+ @summary Scrollbar thumb disappears with Nimbus L&F
+ @author Semyon Sadetsky
+*/
import javax.swing.*;
import java.awt.*;
@@ -78,7 +76,7 @@ public class ScrollBarThumbVisibleTest
SwingUtilities.invokeAndWait(new Runnable() {
@Override
public void run() {
- if (frame != null) { frame.dispose(); }
+ frame.dispose();
}
});
}
diff --git a/jdk/test/javax/swing/plaf/windows/WindowsRootPaneUI/WrongAltProcessing/WrongAltProcessing.java b/jdk/test/javax/swing/plaf/windows/WindowsRootPaneUI/WrongAltProcessing/WrongAltProcessing.java
index 9acfc17fd3..18f4498cfd 100644
--- a/jdk/test/javax/swing/plaf/windows/WindowsRootPaneUI/WrongAltProcessing/WrongAltProcessing.java
+++ b/jdk/test/javax/swing/plaf/windows/WindowsRootPaneUI/WrongAltProcessing/WrongAltProcessing.java
@@ -21,15 +21,12 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 8001633 8028271 8039888
- * @summary Wrong alt processing during switching between windows
- * @author [email protected]
- * @requires (os.family == "windows")
- * @run main WrongAltProcessing
- */
+/* @test
+ @bug 8001633 8028271 8039888
+ @summary Wrong alt processing during switching between windows
+ @author [email protected]
+ @run main WrongAltProcessing
+*/
import javax.swing.*;
import java.awt.*;
diff --git a/jdk/test/javax/swing/system/6799345/TestShutdown.java b/jdk/test/javax/swing/system/6799345/TestShutdown.java
index 114c8beb3f..9a858f1f5b 100644
--- a/jdk/test/javax/swing/system/6799345/TestShutdown.java
+++ b/jdk/test/javax/swing/system/6799345/TestShutdown.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -21,15 +21,13 @@
* questions.
*/
-/**
- * @test
- * @bug 6799345
- * @key headful
- * @summary Tests that no exceptions are thrown from TimerQueue and
- * SwingWorker on AppContext shutdown
- * @author art
- * @run main TestShutdown
- */
+/* @test
+ @bug 6799345
+ @summary Tests that no exceptions are thrown from TimerQueue and
+SwingWorker on AppContext shutdown
+ @author art
+ @run main TestShutdown
+*/
import java.awt.*;
import java.awt.event.*;
diff --git a/jdk/test/javax/swing/text/FlowView/LayoutTest.java b/jdk/test/javax/swing/text/FlowView/LayoutTest.java
index 6b36bb3e64..1cb9effba9 100644
--- a/jdk/test/javax/swing/text/FlowView/LayoutTest.java
+++ b/jdk/test/javax/swing/text/FlowView/LayoutTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2016, 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
@@ -21,15 +21,13 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 6452106 6606443 8161195
- * @author Peter Zhelezniakov
- * @library ../../regtesthelpers
- * @build Test JRobot SwingTestHelper
- * @run main/timeout=300 LayoutTest
- */
+/* @test
+ @bug 6452106 6606443 8161195
+ @author Peter Zhelezniakov
+ @library ../../regtesthelpers
+ @build Test JRobot SwingTestHelper
+ @run main/timeout=300 LayoutTest
+*/
import javax.swing.text.*;
import javax.swing.*;
diff --git a/jdk/test/javax/swing/text/View/8015853/bug8015853.java b/jdk/test/javax/swing/text/View/8015853/bug8015853.java
index c36469b830..f63210683b 100644
--- a/jdk/test/javax/swing/text/View/8015853/bug8015853.java
+++ b/jdk/test/javax/swing/text/View/8015853/bug8015853.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 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
@@ -21,9 +21,8 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 8015853
* @summary Tests the rendering of a large HTML document
* @author Dmitry Markov
diff --git a/jdk/test/javax/swing/text/html/Test4783068.java b/jdk/test/javax/swing/text/html/Test4783068.java
index 7001c7fc0e..b01d042017 100644
--- a/jdk/test/javax/swing/text/html/Test4783068.java
+++ b/jdk/test/javax/swing/text/html/Test4783068.java
@@ -21,13 +21,11 @@
* questions.
*/
-/**
- * @test
- * @key headful
- * @bug 4783068
- * @summary Disabled components should render grayed-out HTML
- * @author Peter Zhelezniakov
- * @run main Test4783068
+/* @test
+ @bug 4783068
+ @summary Disabled components should render grayed-out HTML
+ @author Peter Zhelezniakov
+ @run main Test4783068
*/
import java.awt.*;
diff --git a/jdk/test/jdk/lambda/separate/Compiler.java b/jdk/test/jdk/lambda/separate/Compiler.java
index c047830112..48e25d4e03 100644
--- a/jdk/test/jdk/lambda/separate/Compiler.java
+++ b/jdk/test/jdk/lambda/separate/Compiler.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
+ * 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
@@ -54,7 +54,7 @@ public class Compiler {
private static final AtomicInteger counter = new AtomicInteger();
private static final String targetDir =
System.getProperty("lambda.separate.targetDirectory",
- "." + File.separator + "gen-separate");
+ System.getProperty("java.io.tmpdir") + File.separator + "gen-separate");
private static final File root = new File(targetDir);
private static ConcurrentHashMap<String,File> cache =
new ConcurrentHashMap<>();
@@ -189,7 +189,7 @@ public class Compiler {
StandardLocation.CLASS_OUTPUT, Arrays.asList(destDir));
} catch (IOException e) {
throw new RuntimeException(
- "IOException encountered during compilation: " + e.getMessage(), e);
+ "IOException encountered during compilation");
}
Boolean result = ct.call();
if (result == Boolean.FALSE) {
diff --git a/jdk/test/security/infra/java/security/cert/CertPathValidator/certification/CAInterop.java b/jdk/test/security/infra/java/security/cert/CertPathValidator/certification/CAInterop.java
index a107406e58..ec1a14ae72 100644
--- a/jdk/test/security/infra/java/security/cert/CertPathValidator/certification/CAInterop.java
+++ b/jdk/test/security/infra/java/security/cert/CertPathValidator/certification/CAInterop.java
@@ -376,6 +376,46 @@
* @run main/othervm -Djava.security.debug=certpath CAInterop certignarootca CRL
*/
+/*
+ * @test id=affirmtrustcommercialca
+ * @bug 8040012
+ * @summary Interoperability tests with AffirmTrust Commercial CA
+ * @library /test/lib
+ * @build jtreg.SkippedException ValidatePathWithURL CAInterop
+ * @run main/othervm -Djava.security.debug=certpath,ocsp CAInterop affirmtrustcommercialca OCSP
+ * @run main/othervm -Djava.security.debug=certpath CAInterop affirmtrustcommercialca CRL
+ */
+
+/*
+ * @test id=affirmtrustnetworkingca
+ * @bug 8040012
+ * @summary Interoperability tests with AffirmTrust Networking CA
+ * @library /test/lib
+ * @build jtreg.SkippedException ValidatePathWithURL CAInterop
+ * @run main/othervm -Djava.security.debug=certpath,ocsp CAInterop affirmtrustnetworkingca OCSP
+ * @run main/othervm -Djava.security.debug=certpath CAInterop affirmtrustnetworkingca CRL
+ */
+
+/*
+ * @test id=affirmtrustpremiumca
+ * @bug 8040012
+ * @summary Interoperability tests with AffirmTrust Premium CA
+ * @library /test/lib
+ * @build jtreg.SkippedException ValidatePathWithURL CAInterop
+ * @run main/othervm -Djava.security.debug=certpath,ocsp CAInterop affirmtrustpremiumca OCSP
+ * @run main/othervm -Djava.security.debug=certpath CAInterop affirmtrustpremiumca CRL
+ */
+
+/*
+ * @test id=affirmtrustpremiumeccca
+ * @bug 8040012
+ * @summary Interoperability tests with AffirmTrust Premium ECC CA
+ * @library /test/lib
+ * @build jtreg.SkippedException ValidatePathWithURL CAInterop
+ * @run main/othervm -Djava.security.debug=certpath,ocsp CAInterop affirmtrustpremiumeccca OCSP
+ * @run main/othervm -Djava.security.debug=certpath CAInterop affirmtrustpremiumeccca CRL
+ */
+
/*
* @test id=teliarootcav2
* @bug 8317373
@@ -572,20 +612,20 @@ public class CAInterop {
"https://revoked.sfig2.catest.starfieldtech.com");
case "globalsigneccrootcar4":
- return new CATestURLs("https://good.gsr4.demosite.pki.goog",
- "https://revoked.gsr4.demosite.pki.goog");
+ return new CATestURLs("https://good.gsr4.demo.pki.goog",
+ "https://revoked.gsr4.demo.pki.goog");
case "gtsrootcar1":
- return new CATestURLs("https://good.gtsr1.demosite.pki.goog",
- "https://revoked.gtsr1.demosite.pki.goog");
+ return new CATestURLs("https://good.gtsr1.demo.pki.goog",
+ "https://revoked.gtsr1.demo.pki.goog");
case "gtsrootcar2":
- return new CATestURLs("https://good.gtsr2.demosite.pki.goog",
- "https://revoked.gtsr2.demosite.pki.goog");
+ return new CATestURLs("https://good.gtsr2.demo.pki.goog",
+ "https://revoked.gtsr2.demo.pki.goog");
case "gtsrootecccar3":
- return new CATestURLs("https://good.gtsr3.demosite.pki.goog",
- "https://revoked.gtsr3.demosite.pki.goog");
+ return new CATestURLs("https://good.gtsr3.demo.pki.goog",
+ "https://revoked.gtsr3.demo.pki.goog");
case "gtsrootecccar4":
- return new CATestURLs("https://good.gtsr4.demosite.pki.goog",
- "https://revoked.gtsr4.demosite.pki.goog");
+ return new CATestURLs("https://good.gtsr4.demo.pki.goog",
+ "https://revoked.gtsr4.demo.pki.goog");
case "microsoftecc2017":
return new CATestURLs("https://acteccroot2017.pki.microsoft.com",
@@ -637,6 +677,20 @@ public class CAInterop {
return new CATestURLs("https://juolukka.cover.telia.fi:10600",
"https://juolukka.cover.telia.fi:10601");
+ // These are listed at https://www.affirmtrust.com/resources/
+ case "affirmtrustcommercialca":
+ return new CATestURLs("https://validcommercial.affirmtrust.com",
+ "https://revokedcommercial.affirmtrust.com");
+ case "affirmtrustnetworkingca":
+ return new CATestURLs("https://validnetworking.affirmtrust.com",
+ "https://revokednetworking.affirmtrust.com");
+ case "affirmtrustpremiumca":
+ return new CATestURLs("https://validpremium.affirmtrust.com",
+ "https://revokedpremium.affirmtrust.com");
+ case "affirmtrustpremiumeccca":
+ return new CATestURLs("https://validpremiumecc.affirmtrust.com",
+ "https://revokedpremiumecc.affirmtrust.com");
+
case "emsignrootcag1":
return new CATestURLs("https://testovg1.emsign.com/RootOVG1.html",
"https://testovg1r.emsign.com/RootOVG1MR.html");
diff --git a/jdk/test/sun/java2d/DirectX/IAEforEmptyFrameTest/IAEforEmptyFrameTest.java b/jdk/test/sun/java2d/DirectX/IAEforEmptyFrameTest/IAEforEmptyFrameTest.java
index 39574caa98..e0f54e37da 100644
--- a/jdk/test/sun/java2d/DirectX/IAEforEmptyFrameTest/IAEforEmptyFrameTest.java
+++ b/jdk/test/sun/java2d/DirectX/IAEforEmptyFrameTest/IAEforEmptyFrameTest.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2008, 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
@@ -21,16 +21,14 @@
* questions.
*/
-/**
+/*
* @test
- * @key headful
* @bug 6668439
* @summary Verifies that no exceptions are thrown when frame is resized to 0x0
* @author [email protected]: area=Graphics
* @run main/othervm IAEforEmptyFrameTest
* @run main/othervm -Dsun.java2d.d3d=false IAEforEmptyFrameTest
*/
-
import javax.swing.JFrame;
public class IAEforEmptyFrameTest {
diff --git a/jdk/test/sun/management/HotspotRuntimeMBean/GetTotalSafepointTime.java b/jdk/test/sun/management/HotspotRuntimeMBean/GetTotalSafepointTime.java
index 9933203716..4dccc8871b 100644
--- a/jdk/test/sun/management/HotspotRuntimeMBean/GetTotalSafepointTime.java
+++ b/jdk/test/sun/management/HotspotRuntimeMBean/GetTotalSafepointTime.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2008, 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
@@ -39,33 +39,47 @@ public class GetTotalSafepointTime {
private static HotspotRuntimeMBean mbean =
(HotspotRuntimeMBean)ManagementFactoryHelper.getHotspotRuntimeMBean();
+ private static final long NUM_THREAD_DUMPS = 100;
+
// Careful with these values.
private static final long MIN_VALUE_FOR_PASS = 1;
+ private static final long MAX_VALUE_FOR_PASS = Long.MAX_VALUE;
- // Thread.getAllStackTraces() should cause safepoints.
- // If this test is failing because it doesn't,
- // MIN_VALUE_FOR_PASS should be reset to 0
- public static long executeThreadDumps(long initial_value) {
- long value;
- do {
- Thread.getAllStackTraces();
- value = mbean.getTotalSafepointTime();
- } while (value == initial_value);
- return value;
- }
+ private static boolean trace = false;
public static void main(String args[]) throws Exception {
- long value = executeThreadDumps(0);
- System.out.println("Total safepoint time (ms): " + value);
+ if (args.length > 0 && args[0].equals("trace")) {
+ trace = true;
+ }
+
+ // Thread.getAllStackTraces() should cause safepoints.
+ // If this test is failing because it doesn't,
+ // MIN_VALUE_FOR_PASS should be reset to 0
+ for (int i = 0; i < NUM_THREAD_DUMPS; i++) {
+ Thread.getAllStackTraces();
+ }
+
+ long value = mbean.getTotalSafepointTime();
- if (value < MIN_VALUE_FOR_PASS) {
+ if (trace) {
+ System.out.println("Total safepoint time (ms): " + value);
+ }
+
+ if (value < MIN_VALUE_FOR_PASS || value > MAX_VALUE_FOR_PASS) {
throw new RuntimeException("Total safepoint time " +
"illegal value: " + value + " ms " +
- "(MIN = " + MIN_VALUE_FOR_PASS + ")");
+ "(MIN = " + MIN_VALUE_FOR_PASS + "; " +
+ "MAX = " + MAX_VALUE_FOR_PASS + ")");
}
- long value2 = executeThreadDumps(value);
- System.out.println("Total safepoint time (ms): " + value2);
+ for (int i = 0; i < 2 * NUM_THREAD_DUMPS; i++) {
+ Thread.getAllStackTraces();
+ }
+ long value2 = mbean.getTotalSafepointTime();
+
+ if (trace) {
+ System.out.println("Total safepoint time2 (ms): " + value2);
+ }
if (value2 <= value) {
throw new RuntimeException("Total safepoint time " +
diff --git a/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest11_ok.properties.in b/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest11_ok.properties.in
index b74bb0d1b1..a9bbc864c6 100644
--- a/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest11_ok.properties.in
+++ b/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest11_ok.properties.in
@@ -1,6 +1,6 @@
-com.sun.management.jmxremote.ssl.enabled.cipher.suites=TLS_AES_128_GCM_SHA256,TLS_AES_256_GCM_SHA384
-com.sun.management.jmxremote.ssl.enabled.protocols=SSLv2Hello,SSLv3,TLSv1,TLSv1.1,TLSv1.2,TLSv1.3
+com.sun.management.jmxremote.ssl.enabled.cipher.suites=SSL_RSA_WITH_RC4_128_SHA,SSL_RSA_WITH_RC4_128_MD5
+com.sun.management.jmxremote.ssl.enabled.protocols=SSLv2Hello,SSLv3,TLSv1
com.sun.management.jmxremote.ssl.need.client.auth=true
com.sun.management.jmxremote.ssl.config.file=@TEST-SRC@/jmxremote_ssltest11_ok.ssl
com.sun.management.jmxremote.authenticate=false
-javax.rmi.ssl.client.enabledCipherSuites=TLS_AES_128_GCM_SHA256,TLS_AES_256_GCM_SHA384
+javax.rmi.ssl.client.enabledCipherSuites=SSL_RSA_WITH_RC4_128_SHA,SSL_RSA_WITH_RC4_128_MD5
diff --git a/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest15_ok.properties.in b/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest15_ok.properties.in
deleted file mode 100644
index 37aca8ad55..0000000000
--- a/jdk/test/sun/management/jmxremote/bootstrap/management_ssltest15_ok.properties.in
+++ /dev/null
@@ -1,6 +0,0 @@
-com.sun.management.jmxremote.ssl.enabled.cipher.suites=TLS_RSA_WITH_AES_128_CBC_SHA,TLS_RSA_WITH_AES_256_CBC_SHA
-com.sun.management.jmxremote.ssl.enabled.protocols=SSLv2Hello,SSLv3,TLSv1
-com.sun.management.jmxremote.ssl.need.client.auth=true
-com.sun.management.jmxremote.ssl.config.file=@TEST-SRC@/jmxremote_ssltest11_ok.ssl
-com.sun.management.jmxremote.authenticate=false
-javax.rmi.ssl.client.enabledCipherSuites=TLS_RSA_WITH_AES_128_CBC_SHA,TLS_RSA_WITH_AES_256_CBC_SHA
diff --git a/jdk/test/sun/management/jmxremote/bootstrap/ssl/Readme.txt b/jdk/test/sun/management/jmxremote/bootstrap/ssl/Readme.txt
index 133b3db62c..48b5478ab3 100644
--- a/jdk/test/sun/management/jmxremote/bootstrap/ssl/Readme.txt
+++ b/jdk/test/sun/management/jmxremote/bootstrap/ssl/Readme.txt
@@ -1,10 +1,11 @@
The trustore and keystore are to be generated as follows:
-1. keytool -genkey -alias duke -keyalg RSA -keysize 2048 -validity 36500 -keystore keystore -storepass password
+1. keytool -genkey -alias duke -keystore keystore -validity 36500
- use password 'password' for the keystore and key passwords
- leave all values at default
- the certificate validity will be 100 years (should be enough for now)
2. keytool -export -keystore keystore -alias duke -file duke.crt
-3. keytool -import -alias duke -file duke.crt -keystore truststore -storepass trustword
+3. keytool -import -keystore truststore -alias duke -file duke.crt
- use password 'trustword' for the keystore and key passwords
- leave all values at default
+
diff --git a/jdk/test/sun/management/jmxremote/bootstrap/ssl/keystore b/jdk/test/sun/management/jmxremote/bootstrap/ssl/keystore
index 807a2f0df0..f756c3b0ef 100644
Binary files a/jdk/test/sun/management/jmxremote/bootstrap/ssl/keystore and b/jdk/test/sun/management/jmxremote/bootstrap/ssl/keystore differ
diff --git a/jdk/test/sun/management/jmxremote/bootstrap/ssl/truststore b/jdk/test/sun/management/jmxremote/bootstrap/ssl/truststore
index 7c131cfd7f..3918d41f59 100644
Binary files a/jdk/test/sun/management/jmxremote/bootstrap/ssl/truststore and b/jdk/test/sun/management/jmxremote/bootstrap/ssl/truststore differ
diff --git a/jdk/test/sun/net/www/http/ChunkedOutputStream/CheckError.java b/jdk/test/sun/net/www/http/ChunkedOutputStream/CheckError.java
deleted file mode 100644
index 1fd7d2f3e7..0000000000
--- a/jdk/test/sun/net/www/http/ChunkedOutputStream/CheckError.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * Copyright (c) 2004, 2016, 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 5054016
- * @summary get the failure immediately when writing individual chunks over socket fail
- */
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.OutputStream;
-import java.net.HttpURLConnection;
-import java.net.ServerSocket;
-import java.net.Socket;
-import java.net.URL;
-import static java.lang.System.out;
-
-public class CheckError {
-
- static int BUFFER_SIZE = 8192; // 8k
- static int TOTAL_BYTES = 1 * 1024 * 1024; // 1M
-
- public static void main(String[] args) throws Exception {
-
- HTTPServer server = new HTTPServer();
- server.start();
- int port = server.getPort();
- out.println("Server listening on " + port);
-
-
- URL url = new URL("http://localhost:" + port);
- HttpURLConnection conn = (HttpURLConnection)url.openConnection();
- conn.setRequestMethod("POST");
- conn.setDoOutput(true);
- conn.setChunkedStreamingMode(1024);
-
- out.println("sending " + TOTAL_BYTES + " bytes");
-
- int byteAtOnce;
- int sendingBytes = TOTAL_BYTES;
- byte[] buffer = getBuffer(BUFFER_SIZE);
- try (OutputStream toServer = conn.getOutputStream()) {
- while (sendingBytes > 0) {
- if (sendingBytes > BUFFER_SIZE) {
- byteAtOnce = BUFFER_SIZE;
- } else {
- byteAtOnce = sendingBytes;
- }
- toServer.write(buffer, 0, byteAtOnce);
- sendingBytes -= byteAtOnce;
- out.print((TOTAL_BYTES - sendingBytes) + " was sent. ");
- toServer.flush();
- // gives the server thread time to read, and eventually close;
- Thread.sleep(500);
- }
- } catch (IOException expected) {
- // Expected IOException due to server.close()
- out.println("PASSED. Caught expected: " + expected);
- return;
- }
-
- // Expected IOException not received. FAIL
- throw new RuntimeException("Failed: Expected IOException not received");
- }
-
- static byte[] getBuffer(int size) {
- byte[] buffer = new byte[size];
- for (int i = 0; i < size; i++)
- buffer[i] = (byte)i;
- return buffer;
- }
-
- static class HTTPServer extends Thread {
-
- final ServerSocket serverSocket;
-
- HTTPServer() throws IOException {
- serverSocket = new ServerSocket(0);
- }
-
- int getPort() {
- return serverSocket.getLocalPort();
- }
-
- public void run() {
- try (Socket client = serverSocket.accept()) {
-
- InputStream in = client.getInputStream();
- BufferedReader reader = new BufferedReader(new InputStreamReader(in));
- String line;
- do {
- line = reader.readLine();
- out.println("Server: " + line);
- } while (line != null && line.length() > 0);
-
- System.out.println("Server: receiving some data");
- // just read some data, then close the connection
- in.read(new byte[1024]);
-
- in.close();
- client.close();
- out.println("Server closed socket");
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
-}
diff --git a/jdk/test/sun/net/www/http/ChunkedOutputStream/checkError.java b/jdk/test/sun/net/www/http/ChunkedOutputStream/checkError.java
new file mode 100644
index 0000000000..4575f91e93
--- /dev/null
+++ b/jdk/test/sun/net/www/http/ChunkedOutputStream/checkError.java
@@ -0,0 +1,251 @@
+/*
+ * Copyright (c) 2004, 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 5054016
+ * @run main/othervm/timeout=300 checkError
+ * @summary get the failure immediately when writing individual chunks over socket fail
+ */
+
+import java.io.*;
+import java.net.*;
+import java.util.StringTokenizer;
+
+
+public class checkError {
+ static final int TEST_PASSED = 95;
+ static final int TEST_FAILED = 97;
+
+ static int testStatus = TEST_PASSED;
+
+ static String serverName = "localhost";
+ static int bufferSize = 8192; // 8k
+ static int totalBytes = 1048576; // 1M
+
+ static int j = 0;
+
+ static public Object threadStarting = new Object();
+ static public Object threadWaiting = new Object();
+
+
+ public static void main(String[] args) throws Exception {
+ HttpURLConnection conn = null;
+ OutputStream toServer = null;
+ byte[] buffer = null;
+ HTTPServer server = null;
+ synchronized(threadWaiting) {
+ System.out.println("HTTP-client>Starting default Http-server");
+ synchronized(threadStarting) {
+ server = new HTTPServer();
+ server.start();
+ try {
+ System.out.println("waiting server to be start");
+ threadStarting.wait();
+ } catch (InterruptedException e) {
+ }
+ }
+ int port = server.getPort();
+ URL url = new URL("http://" + serverName + ":" + port);
+ conn = (HttpURLConnection )url.openConnection();
+ conn.setRequestMethod("POST");
+ conn.setDoOutput(true);
+
+ System.out.println("assigning 1024 to the chunk length");
+ conn.setChunkedStreamingMode(1024);
+ conn.connect();
+
+ toServer = conn.getOutputStream();
+ buffer = getThickBuffer(bufferSize);
+ System.out.println("sending " + totalBytes + " bytes");
+ }
+
+ int byteAtOnce = 0;
+ int sendingBytes = totalBytes;
+ try {
+ while (sendingBytes > 0) {
+ if (sendingBytes > bufferSize) {
+ byteAtOnce = bufferSize;
+ } else {
+ byteAtOnce = sendingBytes;
+ }
+ toServer.write(buffer, 0, byteAtOnce);
+ sendingBytes -= byteAtOnce;
+ // System.out.println((totalBytes - sendingBytes) + " was sent");
+ toServer.flush();
+ }
+ } catch (OutOfMemoryError e) {
+ e.printStackTrace();
+ System.out.println("***ERR***> UNEXPECTED error: " + e);
+ testStatus = TEST_FAILED;
+ testExit();
+ } catch (IOException e) {
+ // e.printStackTrace();
+ // this is the expected IOException
+ // due to server.close()
+ testStatus = TEST_PASSED;
+ testExit();
+ } finally {
+ toServer.close();
+ }
+
+ // we have not received the expected IOException
+ // test fail
+ testStatus = TEST_FAILED;
+ testExit();
+
+ }
+
+ static void testExit() {
+ if (testStatus == TEST_FAILED) {
+ throw new RuntimeException("Test Failed: haven't received the expected IOException");
+ } else {
+ System.out.println("TEST PASSED");
+ }
+ System.exit(testStatus);
+ }
+
+ static byte[] getThickBuffer(int size) {
+
+ byte[] buffer = new byte[size];
+
+ for (int i = 0; i < size; i++) {
+ if (j > 9)
+ j = 0;
+ String s = Integer.toString(j);
+ buffer[i] = (byte )s.charAt(0);
+ j++;
+ }
+
+ return buffer;
+ }
+}
+
+
+class HTTPServer extends Thread {
+
+ static volatile boolean isCompleted;
+
+ Socket client;
+ ServerSocket serverSocket;
+
+ int getPort() {
+ return serverSocket.getLocalPort();
+ }
+
+ public void run() {
+
+ synchronized(checkError.threadStarting) {
+
+ try {
+ serverSocket = new ServerSocket(0, 100);
+ } catch (Exception e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ }
+ checkError.threadStarting.notify();
+ }
+
+ try {
+ client = serverSocket.accept();
+ } catch (Exception e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ }
+
+ System.out.println("Server started");
+
+ BufferedReader in = null;
+ PrintStream out = null;
+ InputStreamReader reader = null;
+ String version = null;
+ String line;
+ String method;
+
+ synchronized(checkError.threadWaiting) {
+ try {
+ reader = new InputStreamReader(client.getInputStream());
+ in = new BufferedReader(reader);
+ line = in.readLine();
+
+ } catch (Exception e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ }
+ StringTokenizer st = new StringTokenizer(line);
+ method = st.nextToken();
+ String fileName = st.nextToken();
+
+ // save version for replies
+ if (st.hasMoreTokens()) version = st.nextToken();
+
+ System.out.println("HTTP version: " + version);
+
+ }
+
+ try {
+
+ while (line != null && line.length() > 0) {
+ line = in.readLine();
+ System.out.println(line);
+ }
+ } catch (IOException e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ }
+
+ if (method.equals("POST")) {
+ System.out.println("receiving data");
+ byte[] buf = new byte[1024];
+ try {
+ //reading bytes until chunk whose size is zero,
+ // see 19.4.6 Introduction of Transfer-Encoding in RFC2616
+ int count = 0;
+ while (count <=5) {
+ count++;
+ in.readLine();
+ }
+
+ System.out.println("Server socket is closed");
+ in.close();
+ client.close();
+ serverSocket.close();
+
+ } catch (IOException e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ } catch (OutOfMemoryError e) {
+ e.printStackTrace();
+ checkError.testStatus = checkError.TEST_FAILED;
+ return;
+ }
+
+ }
+ }
+
+}
diff --git a/jdk/test/sun/security/lib/cacerts/VerifyCACerts.java b/jdk/test/sun/security/lib/cacerts/VerifyCACerts.java
index 8a24197f1b..dbd69e0bfe 100644
--- a/jdk/test/sun/security/lib/cacerts/VerifyCACerts.java
+++ b/jdk/test/sun/security/lib/cacerts/VerifyCACerts.java
@@ -28,7 +28,7 @@
* 8223499 8225392 8232019 8234245 8233223 8225068 8225069 8243321 8243320
* 8243559 8225072 8258630 8259312 8256421 8225081 8225082 8225083 8245654
* 8305975 8304760 8307134 8295894 8314960 8317373 8317374 8318759 8319187
- * 8321408 8316138 8341057 8303770 8350498 8359170 8361212
+ * 8321408 8316138 8341057 8303770 8350498 8359170
* @summary Check root CA entries in cacerts file
*/
import java.io.ByteArrayInputStream;
@@ -54,12 +54,12 @@ public class VerifyCACerts {
+ File.separator + "security" + File.separator + "cacerts";
// The numbers of certs now.
- private static final int COUNT = 109;
+ private static final int COUNT = 113;
// SHA-256 of cacerts, can be generated with
// shasum -a 256 cacerts | sed -e 's/../&:/g' | tr '[:lower:]' '[:upper:]' | cut -c1-95
private static final String CHECKSUM
- = "F2:0C:60:47:49:FA:13:2A:03:A4:52:20:AD:46:7C:D0:3F:3D:A7:59:D6:27:E9:9B:CC:D4:5A:04:8D:2A:DE:9F";
+ = "1E:63:88:DF:34:AD:7E:61:3F:06:BD:C4:DC:FE:05:52:9B:0D:86:6E:64:DA:E8:25:7C:C0:15:8F:31:C0:2C:78";
// map of cert alias to SHA-256 fingerprint
@SuppressWarnings("serial")
@@ -198,6 +198,14 @@ public class VerifyCACerts {
"43:DF:57:74:B0:3E:7F:EF:5F:E4:0D:93:1A:7B:ED:F1:BB:2E:6B:42:73:8C:4E:6D:38:41:10:3D:3A:A7:F3:39");
put("entrustevca [jdk]",
"73:C1:76:43:4F:1B:C6:D5:AD:F4:5B:0E:76:E7:27:28:7C:8D:E5:76:16:C1:E6:E6:14:1A:2B:2C:BC:7D:8E:4C");
+ put("affirmtrustnetworkingca [jdk]",
+ "0A:81:EC:5A:92:97:77:F1:45:90:4A:F3:8D:5D:50:9F:66:B5:E2:C5:8F:CD:B5:31:05:8B:0E:17:F3:F0:B4:1B");
+ put("affirmtrustpremiumca [jdk]",
+ "70:A7:3F:7F:37:6B:60:07:42:48:90:45:34:B1:14:82:D5:BF:0E:69:8E:CC:49:8D:F5:25:77:EB:F2:E9:3B:9A");
+ put("affirmtrustcommercialca [jdk]",
+ "03:76:AB:1D:54:C5:F9:80:3C:E4:B2:E2:01:A0:EE:7E:EF:7B:57:B6:36:E8:A9:3C:9B:8D:48:60:C9:6F:5F:A7");
+ put("affirmtrustpremiumeccca [jdk]",
+ "BD:71:FD:F6:DA:97:E4:CF:62:D1:64:7A:DD:25:81:B0:7D:79:AD:F8:39:7E:B4:EC:BA:9C:5E:84:88:82:14:23");
put("ttelesecglobalrootclass3ca [jdk]",
"FD:73:DA:D3:1C:64:4F:F1:B4:3B:EF:0C:CD:DA:96:71:0B:9C:D9:87:5E:CA:7E:31:70:7A:F3:E9:6D:52:2B:BD");
put("ttelesecglobalrootclass2ca [jdk]",
diff --git a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/Entrust.java b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/Entrust.java
index 36c7ecc854..1cc2b55ae5 100644
--- a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/Entrust.java
+++ b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/Entrust.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2024, 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
@@ -28,7 +28,7 @@ import javax.net.ssl.*;
/**
* @test
- * @bug 8337664 8341059 8361212
+ * @bug 8337664 8341059
* @summary Check that TLS Server certificates chaining back to distrusted
* Entrust roots are invalid
* @library /lib/security
@@ -40,13 +40,14 @@ import javax.net.ssl.*;
public class Entrust {
- private static final String CERT_PATH = "chains" + File.separator + "entrust";
+ private static final String certPath = "chains" + File.separator + "entrust";
// Each of the roots have a test certificate chain stored in a file
// named "<root>-chain.pem".
- private static final String[] ROOTS_TO_TEST = new String[]{
- "entrustevca", "entrustrootcaec1", "entrustrootcag2",
- "entrustrootcag4", "entrust2048ca"};
+ private static String[] rootsToTest = new String[]{
+ "entrustevca", "entrustrootcaec1", "entrustrootcag2", "entrustrootcag4",
+ "entrust2048ca", "affirmtrustcommercialca", "affirmtrustnetworkingca",
+ "affirmtrustpremiumca", "affirmtrustpremiumeccca"};
// Date when the restrictions take effect
private static final ZonedDateTime DISTRUST_DATE =
@@ -61,6 +62,6 @@ public class Entrust {
};
Date notBefore = distrust.getNotBefore(DISTRUST_DATE);
- distrust.testCertificateChain(CERT_PATH, notBefore, tms, ROOTS_TO_TEST);
+ distrust.testCertificateChain(certPath, notBefore, tms, rootsToTest);
}
}
diff --git a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustcommercialca-chain.pem b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustcommercialca-chain.pem
new file mode 100644
index 0000000000..76aa6d1433
--- /dev/null
+++ b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustcommercialca-chain.pem
@@ -0,0 +1,77 @@
+Root Certificate:
+ Version: 3 (0x2)
+ Serial Number: 8608355977964138876 (0x7777062726a9b17c)
+ Signature Algorithm: sha256WithRSAEncryption
+ Issuer: C=US, O=AffirmTrust, CN=AffirmTrust Commercial
+ Validity
+ Not Before: Jan 29 14:06:06 2010 GMT
+ Not After : Dec 31 14:06:06 2030 GMT
+
+-----BEGIN CERTIFICATE-----
+MIIHHjCCBgagAwIBAgIQAWZjFOyCvT00u/gtkCvS2TANBgkqhkiG9w0BAQsFADCB
+gzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYDVQQLEyJT
+ZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQDEyhBZmZp
+cm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYxMB4XDTI0MDYyODIx
+MzgwNVoXDTI1MDcyODIxMzgwNFowgdgxCzAJBgNVBAYTAkNBMRAwDgYDVQQIEwdP
+bnRhcmlvMQ8wDQYDVQQHEwZPdHRhd2ExEzARBgsrBgEEAYI3PAIBAxMCQ0ExGDAW
+BgsrBgEEAYI3PAIBAhMHT250YXJpbzEcMBoGA1UEChMTQWZmaXJtdHJ1c3QgTGlt
+aXRlZDEdMBsGA1UEDxMUUHJpdmF0ZSBPcmdhbml6YXRpb24xEDAOBgNVBAUTBzI1
+NDA1NDcxKDAmBgNVBAMTH3ZhbGlkY29tbWVyY2lhbC5hZmZpcm10cnVzdC5jb20w
+ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDeIT2XO0hJ5wDSbIiIcMvs
+P3NpQc7O7v5DqldpME6+Qn2sF5b9hc6j72hgTXREa77uUcP5u1JcMWCSWwYQHMpJ
+kFzmIzijhS60wW1epb5QyTgM3ZYh1WKvttFCbHUcrTtd+LoPFYsjw9ZK//K9tPp+
+ddn06/ivWvUO5y5vn0wrCaB9tuLdDn4RCQzK2XoZdDuqhPlBBogJX0vM6lsXjgLy
+EbvE+/sKYps/In6VtRvCoYavg3OqaIMeaA7gTiYTb1ZGFOAiltnq7fcp6SZUohK3
+QNihv1DadVc+n8LnEUKKDkgG2YgWEFczaE3qwG3ef6L3MzLGrkgVY+qGHyyv2IE7
+AgMBAAGjggM1MIIDMTAMBgNVHRMBAf8EAjAAMB0GA1UdDgQWBBT4ARNL47hAsOpa
+96VMgKEY3sLIAjAfBgNVHSMEGDAWgBTb72U3C+VHyzXRkB8DwbyIx6fqgDBsBggr
+BgEFBQcBAQRgMF4wJwYIKwYBBQUHMAGGG2h0dHA6Ly9vY3NwLmFmZmlybXRydXN0
+LmNvbTAzBggrBgEFBQcwAoYnaHR0cDovL2FpYS5hZmZpcm10cnVzdC5jb20vYWZ0
+ZXYxY2EuY3J0MDwGA1UdHwQ1MDMwMaAvoC2GK2h0dHA6Ly9jcmwuYWZmaXJtdHJ1
+c3QuY29tL2NybC9hZnRldjFjYS5jcmwwKgYDVR0RBCMwIYIfdmFsaWRjb21tZXJj
+aWFsLmFmZmlybXRydXN0LmNvbTAOBgNVHQ8BAf8EBAMCBaAwHQYDVR0lBBYwFAYI
+KwYBBQUHAwEGCCsGAQUFBwMCMFYGA1UdIARPME0wBwYFZ4EMAQEwQgYKKwYBBAGC
+jwkCATA0MDIGCCsGAQUFBwIBFiZodHRwczovL3d3dy5hZmZpcm10cnVzdC5jb20v
+cmVwb3NpdG9yeTCCAYAGCisGAQQB1nkCBAIEggFwBIIBbAFqAHcAEvFONL1TckyE
+BhnDjz96E/jntWKHiJxtMAWE6+WGJjoAAAGQYMi3wQAABAMASDBGAiEAjvdsU4G2
+o4BZSOOjaH6gOp7zhKtXQByQUvfHfsi2ePcCIQDnnIO2qlHBm+sskUDlXfR0lCUW
+yFPVr9nFZ0L9YPpozgB2AA3h8jAr0w3BQGISCepVLvxHdHyx1+kw7w5CHrR+Tqo0
+AAABkGDIt9MAAAQDAEcwRQIhANh1zS3Qeo9yKF+j3G52JhmDRYBS+1TM0wykoXCY
+llpxAiAG+LAlKSbwwgrboUSTDDXWNeoRYZ7fKbU72kKfHrpZvwB3ABoE/0nQVB1A
+r/agw7/x2MRnL07s7iNAaJhrF0Au3Il9AAABkGDIt9sAAAQDAEgwRgIhAN8OoC4I
+zw8bFJy8ACgK40c9ZfsIfFhePTc9CyrL5uDsAiEA4Jn/IqBB9L5DeTgqw9hBaYag
+FmY/2gWDip36ga0WUsAwDQYJKoZIhvcNAQELBQADggEBABywPLJP097Emz6LNeFU
+/HvfhaUKv2pgIHf/Kvjs5x78RK9G605THPEHr/TeUjNZ4PBd48WBNVWzyd/8FuOt
+r+FsYkRJb9CnrOhZHuCwlcdWXvuY8PiuBmT+xB16BWR5yhYbbiGe4hea0Pf6CfHh
+jJoGJw4dQKfgneZOV7IcaWnNTKYawlcZOgxvEwFvj+iZM31WphEPKRAV+N+Tp+ZR
+nxlEdjmdbOjqBydlYIEzuFIgxgtnPdK5wqCOWb+z2cARUAO/AkiWrOLTPDc7ydQK
+GcfDrSqffHOlwaee08C6STFaJWIcpqxZdXE6Jc+8/85bfPEAG1UepgfnBTqW9RGT
+Q3s=
+-----END CERTIFICATE-----
+-----BEGIN CERTIFICATE-----
+MIIEqDCCA5CgAwIBAgIQFylVHtaOf7Ht9XMA811/1TANBgkqhkiG9w0BAQsFADBE
+MQswCQYDVQQGEwJVUzEUMBIGA1UECgwLQWZmaXJtVHJ1c3QxHzAdBgNVBAMMFkFm
+ZmlybVRydXN0IENvbW1lcmNpYWwwHhcNMTkwMzIxMjAyNzU0WhcNMzAxMjAyMDQw
+MDAwWjCBgzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYD
+VQQLEyJTZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQD
+EyhBZmZpcm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYxMIIBIjAN
+BgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuPBMIa9VuXJGAw0MHvieGciPFA11
+b9T49YJ7T+zVpoMMQO+ueUKVHb2l26oeCiwIhXMQ5LquOVcx+rofouzcKXY3wKDZ
+zHIOnAkU+23Ucn/3dRH7aHJULsBufZq+NvwgYSgJJEDKfqvIV/c5HiRyZ2H+nAI5
+10Q2xC0UxgSBsufccQ+Fwkg6BAGDlTXrvi8wi75UaGue6jv/qcKLybeVUrgqKE64
+d9oa9PG5/g89QwSdsIQEdVSFzFvFpOG9YhJbJ177Zg6DGCxU0lWwFrVpyH/2vnXl
+jhMQScn8UxzCJdDg3EDqjgaV0JH2yoLug+QVYgURPu5BEb5ut9vAdP7cLwIDAQAB
+o4IBVDCCAVAwNwYIKwYBBQUHAQEEKzApMCcGCCsGAQUFBzABhhtodHRwOi8vb2Nz
+cC5hZmZpcm10cnVzdC5jb20wHQYDVR0OBBYEFNvvZTcL5UfLNdGQHwPBvIjHp+qA
+MBIGA1UdEwEB/wQIMAYBAf8CAQAwHwYDVR0jBBgwFoAUnZPGU4teyq8/nx4P5ZmV
+vCT2lI8wRwYDVR0gBEAwPjA8BgRVHSAAMDQwMgYIKwYBBQUHAgEWJmh0dHBzOi8v
+d3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MEkGA1UdHwRCMEAwPqA8oDqG
+OGh0dHA6Ly9jcmwuYWZmaXJtdHJ1c3QuY29tL2NybC9BZmZpcm1UcnVzdENvbW1l
+cmNpYWwuY3JsMA4GA1UdDwEB/wQEAwIBhjAdBgNVHSUEFjAUBggrBgEFBQcDAQYI
+KwYBBQUHAwIwDQYJKoZIhvcNAQELBQADggEBAATH11fMrINGmQGQqQW0ATteVnUG
+LrmRSN2OlmRm+dkUwKXhcQQEfYYlEggPqgvxSUpw13fXSOqVHqAcj3BIqF957kh+
+m3DmC0RX9KaEKD165pf77P5nZcRmZpBl9cctvzIxN19uzcminchusYwLyeWhBtTZ
+xpER9LbrfMNaQ7GnrgalMx54QvdjOhw/GJs9/SqEzYmPshL+DzgZX/oAzY63rQIh
+rBblf6/2talZqci96oFzNst8rGfPy/xQ7lgkki1hwIYbORMfloBhP+vAZJo0mxdM
+ipu3Z0ToK+KU2iqnBxXVr2/kod+CpkHnjUHa1wnQuSaefng3XwZ/vqtSL9c=
+-----END CERTIFICATE-----
diff --git a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustnetworkingca-chain.pem b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustnetworkingca-chain.pem
new file mode 100644
index 0000000000..7384d31152
--- /dev/null
+++ b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustnetworkingca-chain.pem
@@ -0,0 +1,76 @@
+Root Certificate:
+ Version: 3 (0x2)
+ Serial Number: 8957382827206547757 (0x7c4f04391cd4992d)
+ Signature Algorithm: sha1WithRSAEncryption
+ Issuer: C=US, O=AffirmTrust, CN=AffirmTrust Networking
+ Validity
+ Not Before: Jan 29 14:08:24 2010 GMT
+ Not After : Dec 31 14:08:24 2030 GMT
+
+-----BEGIN CERTIFICATE-----
+MIIHGjCCBgKgAwIBAgIQX2vGPaCJ1tS0ncp2OlBMFjANBgkqhkiG9w0BAQsFADCB
+gzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYDVQQLEyJT
+ZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQDEyhBZmZp
+cm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYzMB4XDTI0MDYyODIx
+NDU0OVoXDTI1MDcyODIxNDU0OFowgdgxCzAJBgNVBAYTAkNBMRAwDgYDVQQIEwdP
+bnRhcmlvMQ8wDQYDVQQHEwZPdHRhd2ExEzARBgsrBgEEAYI3PAIBAxMCQ0ExGDAW
+BgsrBgEEAYI3PAIBAhMHT250YXJpbzEcMBoGA1UEChMTQWZmaXJtdHJ1c3QgTGlt
+aXRlZDEdMBsGA1UEDxMUUHJpdmF0ZSBPcmdhbml6YXRpb24xEDAOBgNVBAUTBzI1
+NDA1NDcxKDAmBgNVBAMTH3ZhbGlkbmV0d29ya2luZy5hZmZpcm10cnVzdC5jb20w
+ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCkGknE8kFr+CaIybQrDPRw
+z9OKXq77p4CnrkF1/g9w/HiIs6Ps8YqTjsiTKM3wYLbvPA+TbO9DpCSyCP2bVyLf
+AjUE617KZSpfy9RqzvGjn/1qH/cBKohhEliMfDj4ZHfY4x+1WYTZPVK/g0Ny5RAP
+wz9lJHR2SsVGLvpqXzWaVoxifJ8HZWD7n5z/75WeYko+Hubx3WvzJZcN2Xjn+q6a
+7wkDaXPayrvn5uWGPlOLQHqJ5z7wts21jASMTfJAToFyzH6dGwvqxkP3bVJGJ8AF
+vtMfqVjcOcjWgmmOEHMPAAqs5QKrYuSLccH6hFTwFEUCdMwVqfloznt2sNUSBoKj
+AgMBAAGjggMxMIIDLTAMBgNVHRMBAf8EAjAAMB0GA1UdDgQWBBTrE0z4fRyx9P9M
+0FfA6VgGkJiYVDAfBgNVHSMEGDAWgBR5HrHJF8cerLHHFNfD6H+8uVCbFTBsBggr
+BgEFBQcBAQRgMF4wJwYIKwYBBQUHMAGGG2h0dHA6Ly9vY3NwLmFmZmlybXRydXN0
+LmNvbTAzBggrBgEFBQcwAoYnaHR0cDovL2FpYS5hZmZpcm10cnVzdC5jb20vYWZ0
+ZXYzY2EuY3J0MDwGA1UdHwQ1MDMwMaAvoC2GK2h0dHA6Ly9jcmwuYWZmaXJtdHJ1
+c3QuY29tL2NybC9hZnRldjNjYS5jcmwwKgYDVR0RBCMwIYIfdmFsaWRuZXR3b3Jr
+aW5nLmFmZmlybXRydXN0LmNvbTAOBgNVHQ8BAf8EBAMCBaAwHQYDVR0lBBYwFAYI
+KwYBBQUHAwEGCCsGAQUFBwMCMFYGA1UdIARPME0wBwYFZ4EMAQEwQgYKKwYBBAGC
+jwkCAjA0MDIGCCsGAQUFBwIBFiZodHRwczovL3d3dy5hZmZpcm10cnVzdC5jb20v
+cmVwb3NpdG9yeTCCAXwGCisGAQQB1nkCBAIEggFsBIIBaAFmAHYADeHyMCvTDcFA
+YhIJ6lUu/Ed0fLHX6TDvDkIetH5OqjQAAAGQYM/MjQAABAMARzBFAiBjnehs1mvh
+5Xm3uXZ7Bq8gijwiXThwnLSYROQxnWrnbAIhALbgJG+PRZQfzTBbgM/zAwNsBjhe
+F5iENnaajJCxzOhaAHUAEvFONL1TckyEBhnDjz96E/jntWKHiJxtMAWE6+WGJjoA
+AAGQYM/MgQAABAMARjBEAiAsWOm1IIjaxQP9uaPI9tQmkiJPUOTrBTsTDO+jkgiG
++QIgVNhND82rsFGjrtAAHzzgCVzLDUM3zaHxnP/z3BNuO4QAdQAaBP9J0FQdQK/2
+oMO/8djEZy9O7O4jQGiYaxdALtyJfQAAAZBgz8zLAAAEAwBGMEQCIBIGxtjk7Lw8
+i+oggK7VrPMNTB632t321cwhEm517BbZAiBws3+uytwh59N6qGJUuSFQnOZNPOPj
+eQnH2fSdT1J2sDANBgkqhkiG9w0BAQsFAAOCAQEAcSzitESRKlbcUvxvUB7FjK0I
+CaBU1Nyu0xDFCoG2pmp7GASJz34wtPYfsiX5+j4hDh/noMcgk7WlD8pzgWYw15Rk
++5kTv2v4U85y/JFjzMOHbz64KjQdGebqhjvC/E/EXxK+AZf4H574/w7rbyJ30vFL
+gNvPF9AxS1MuYIO55jXrHMByKnFoQZgPsmAY/x+n+OzMxWOdR18PupypCB5TyJZ8
+pQzwoxmX7qeZHiXyJ8jQUwe1qoQc2SbwfQxfwSPUPSJuQo90N+5nyQMe7vvPBM0Y
+/CXaFpfPqh71D4C0Ey+0hYxSt99gYs4P9twUByjIlP0wTyhaoEpt3zw9DdZypQ==
+-----END CERTIFICATE-----
+-----BEGIN CERTIFICATE-----
+MIIEqDCCA5CgAwIBAgIQNCSh7Pjwo1/nRrcBHEPoRDANBgkqhkiG9w0BAQsFADBE
+MQswCQYDVQQGEwJVUzEUMBIGA1UECgwLQWZmaXJtVHJ1c3QxHzAdBgNVBAMMFkFm
+ZmlybVRydXN0IE5ldHdvcmtpbmcwHhcNMTkwMzIxMjAzODU5WhcNMzAxMjAyMDQw
+MDAwWjCBgzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYD
+VQQLEyJTZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQD
+EyhBZmZpcm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYzMIIBIjAN
+BgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmHDl/3xr1qiHoe0Rzb3AGLw56e9J
+l2a3X59+PAfI5wGBHuK9Dl7XsyoH65X6QIC/rXyVpuNgKbbwIGHB+rCSplyHzGyC
+WeM3LXa2q1US7VteeFDS959nxJVRFfwATR9xAK6YTUWQ/yWdw0dZSm0lQNmEMBwS
+qi0ufWokiWXZUzWHOu7A6driCohu9sFDwe1INJUPH6uIlovmzGvG3UYbUSymJcjs
+Ka0fXXX9zukco8exlOIKWRJSNLxKtSSPDVASrGLQ1xi3qkiLTKci3+jKMNDFf1vw
+foZN99HhUcWKXfr2KlWfANdjTMlsTKCfuhfWl1OBVNHGRrACAQCXI/ji0wIDAQAB
+o4IBVDCCAVAwNwYIKwYBBQUHAQEEKzApMCcGCCsGAQUFBzABhhtodHRwOi8vb2Nz
+cC5hZmZpcm10cnVzdC5jb20wHQYDVR0OBBYEFHkesckXxx6ssccU18Pof7y5UJsV
+MBIGA1UdEwEB/wQIMAYBAf8CAQAwHwYDVR0jBBgwFoAUBx/S55zawm6iQLSwelAQ
+UHTEyL0wRwYDVR0gBEAwPjA8BgRVHSAAMDQwMgYIKwYBBQUHAgEWJmh0dHBzOi8v
+d3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MEkGA1UdHwRCMEAwPqA8oDqG
+OGh0dHA6Ly9jcmwuYWZmaXJtdHJ1c3QuY29tL2NybC9BZmZpcm1UcnVzdE5ldHdv
+cmtpbmcuY3JsMA4GA1UdDwEB/wQEAwIBhjAdBgNVHSUEFjAUBggrBgEFBQcDAQYI
+KwYBBQUHAwIwDQYJKoZIhvcNAQELBQADggEBAAhmE4I56hNpnWXQ2Si8a/TgQUZr
+X5Jlv1LDvl3rkDyfEIHNZ8dth17SakJYJBWHExph/iIYjCJ9YmeyhghV5rPqT+wF
+4yyE2ngenIusfnWT2bTpT9u2VZbCNeACE5XnN2UHSA0J9idPjfLuthViWEvSZZUh
+DJ53bX+exO366nDY4AI7owIyhz8hdsWyhZ/0ST+eD+kbgd8osd+GdxzRmyKcfl84
+D1K1uff01T9w2dyUaZglQsFljkaO6xmeXZJsPnhwCp/HlMHWzhAneUQ7I9FZSOW+
+WiYbt4RitmBpysadBReikWM4knECzJQ/fMT9vC0k9BLlqUYRwCH9vr0UnZo=
+-----END CERTIFICATE-----
diff --git a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumca-chain.pem b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumca-chain.pem
new file mode 100644
index 0000000000..6f108bc122
--- /dev/null
+++ b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumca-chain.pem
@@ -0,0 +1,88 @@
+Root Certificate:
+ Version: 3 (0x2)
+ Serial Number: 7893706540734352110 (0x6d8c1446b1a60aee)
+ Signature Algorithm: sha384WithRSAEncryption
+ Issuer: C=US, O=AffirmTrust, CN=AffirmTrust Premium
+ Validity
+ Not Before: Jan 29 14:10:36 2010 GMT
+ Not After : Dec 31 14:10:36 2040 GMT
+
+-----BEGIN CERTIFICATE-----
+MIIIFjCCBv6gAwIBAgIQQVOTWr7tEAJXmRDkCSxkajANBgkqhkiG9w0BAQsFADCB
+gzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYDVQQLEyJT
+ZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQDEyhBZmZp
+cm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYyMB4XDTI0MDYyODIx
+NDgyN1oXDTI1MDcyODIxNDgyNlowgdUxCzAJBgNVBAYTAkNBMRAwDgYDVQQIEwdP
+bnRhcmlvMQ8wDQYDVQQHEwZPdHRhd2ExEzARBgsrBgEEAYI3PAIBAxMCQ0ExGDAW
+BgsrBgEEAYI3PAIBAhMHT250YXJpbzEcMBoGA1UEChMTQWZmaXJtdHJ1c3QgTGlt
+aXRlZDEdMBsGA1UEDxMUUHJpdmF0ZSBPcmdhbml6YXRpb24xEDAOBgNVBAUTBzI1
+NDA1NDcxJTAjBgNVBAMTHHZhbGlkcHJlbWl1bS5hZmZpcm10cnVzdC5jb20wggIi
+MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDVRMzwbDq47ivHOKqJdiEJNL2+
+g9Snj/BRctqcQTrIV99RP0pmAh5fHg7vnhVsHqc9sRLVcQWTJk9NuRJ2VnDKWsBa
+Xrp5UWaNjS0vaFA4jzCi1gWzTTZgPTQn3VRG3JP1F5CZb405/mtWDaw/CfWkcUqQ
+VSilqFlJRsjcPCzQh7ZaXAo+FmzJxNSwjxdP6JSYMeTDRCUpSb3T8PypVI1CEmLZ
+jsxrg5oIZn25591g/pzgLE56N0stNY4d3q4YD1t5x46RsqYAJYSkk8rcTN+kHzsY
+VSqaRDyPkGbmuCeJUvW24wJ30yQtXQWA+U0dMYLe7LyglJ7dkOzvWNbqrIcvM8My
+hxH/wwVH7e4dL/1E58yr1BHENUk7Mp9rzIXj496eLkF5G1lMkNnuVRQqCAOW0rPY
+V0rI8yrCMTK52s4mNjQo2J7JOYdTUvAWZ92MKvEjjhQlMH8eK72Km/+mkxpsgGmr
+3c6u+Gom7oI5VaLZ+3p2uWaOsutk1tkzWjhzY4L27hwmIdWujfrWMRx8uxcfoJxX
+gQ40d1QiSN51BtCPE5UnpLU/YUxMdzWmtUoGUfYIGVqDVToBnunIFMdmFjC0IrNl
+hquDQi/OGMpzuOvxX1FoXb+rRwOhhdrcR0BQqUVRTV0U5LlcsDeNMqmqPE9mzGtJ
+W69Fsh7crntng/L72wIDAQABo4IDMDCCAywwDAYDVR0TAQH/BAIwADAdBgNVHQ4E
+FgQU3PWyi/4usZghgahc/Tj+Q60QLOcwHwYDVR0jBBgwFoAUc3yaOGg8UXxBCP6h
+HyoetGHbzTwwbAYIKwYBBQUHAQEEYDBeMCcGCCsGAQUFBzABhhtodHRwOi8vb2Nz
+cC5hZmZpcm10cnVzdC5jb20wMwYIKwYBBQUHMAKGJ2h0dHA6Ly9haWEuYWZmaXJt
+dHJ1c3QuY29tL2FmdGV2MmNhLmNydDA8BgNVHR8ENTAzMDGgL6AthitodHRwOi8v
+Y3JsLmFmZmlybXRydXN0LmNvbS9jcmwvYWZ0ZXYyY2EuY3JsMCcGA1UdEQQgMB6C
+HHZhbGlkcHJlbWl1bS5hZmZpcm10cnVzdC5jb20wDgYDVR0PAQH/BAQDAgWgMB0G
+A1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjBWBgNVHSAETzBNMAcGBWeBDAEB
+MEIGCisGAQQBgo8JAgMwNDAyBggrBgEFBQcCARYmaHR0cHM6Ly93d3cuYWZmaXJt
+dHJ1c3QuY29tL3JlcG9zaXRvcnkwggF+BgorBgEEAdZ5AgQCBIIBbgSCAWoBaAB2
+ABoE/0nQVB1Ar/agw7/x2MRnL07s7iNAaJhrF0Au3Il9AAABkGDSN7EAAAQDAEcw
+RQIgVDWwhv7yG6RNnkMZnVq1YYA7ypn/GSH0ibUKnESHRpYCIQCY8gyCX7VFONUI
+QuR8daz7ra2FCUI9TwylrR3eFfIgGgB3AN3cyjSV1+EWBeeVMvrHn/g9HFDf2wA6
+FBJ2Ciysu8gqAAABkGDSN5cAAAQDAEgwRgIhAM1edsSyFUKU0Dj1WxTGwziE6fCW
+g2ByfL8kDrP260YXAiEA6YQOpJf04N13Nn263BxAl+laH9Ar0eo03fArlv743TQA
+dQAN4fIwK9MNwUBiEgnqVS78R3R8sdfpMO8OQh60fk6qNAAAAZBg0je+AAAEAwBG
+MEQCIExqK4katETAQo+H0+ImuNJCSeFEI9C+9wrjhl6ZnWb9AiBwkC1vpLYOIm/1
+YCLCQIOmTdg2wf8LITlrQNJA8vbBljANBgkqhkiG9w0BAQsFAAOCAQEASOmPu7ot
+yl6MoMns19uI6H2KSUjMFh3/fKMcY/ettmEYalgrytexFMrLnD2UniBlD+nJEshp
+5/z7o0YDiRoiLhMAs7VqIdX3erNu/ghNh7P2bDnoMWShSoAKxez1XOGL3rRE0NAi
+DsWCaNRHH9rnC97275sbGnua7ZYg+8BiF62vpJlqjrxDHjGiej8qAWSjztbB43Af
+bwRscpXTxNkMvOBuRFMH+rSxB8CrOV68W+yxmzPuPxVjM7oJH8Qk5BC53NRqFsVz
+JhbNfot0+/drj7JT3jlacUVQcD/BzDuC3+qczQlLjLdHgQM2/e4fXsD6C5S6B11d
+BDx6ipGpaASofA==
+-----END CERTIFICATE-----
+-----BEGIN CERTIFICATE-----
+MIIFojCCA4qgAwIBAgIQU3HI6weE/VEI5dTz4yPsRjANBgkqhkiG9w0BAQsFADBB
+MQswCQYDVQQGEwJVUzEUMBIGA1UECgwLQWZmaXJtVHJ1c3QxHDAaBgNVBAMME0Fm
+ZmlybVRydXN0IFByZW1pdW0wHhcNMTkwMzIxMjA0NjM1WhcNMzAxMjAyMDQwMDAw
+WjCBgzELMAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYDVQQL
+EyJTZWUgd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTEwLwYDVQQDEyhB
+ZmZpcm1UcnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVYyMIIBIjANBgkq
+hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAvDDZHfxkB1nAGFKdw0VCgV+B/eBtW1o+
+bXzwRcpeFh5saDI+tv1RAMrYFq+AJkXCCJopgMF2Wqfv5myE3JMgxEHuuKUpJz7H
+FprrFckVOGCtJKH8Iy9AWPjBwt8lKmxGJF7EZst+QoVt4hMe0qhL0WEKbATFPe41
+DcM7UsyQv6Bvpn424uePy3/1ATIsVL3YmvAbUNR0aqVxYAJzTefvyIet/761bKGc
+NyqdOVWFFeTDtr8iL1TBXToAgl0GJ39bFQZsP19VcCpfk9Zj3YHTPRPq5wZOZuUN
+F7jiBUEi6DaVOi3Wy4vdySHtWPeBHRYif1I6fcUfdCNORMc4ee6KewIDAQABo4IB
+UTCCAU0wNwYIKwYBBQUHAQEEKzApMCcGCCsGAQUFBzABhhtodHRwOi8vb2NzcC5h
+ZmZpcm10cnVzdC5jb20wHQYDVR0OBBYEFHN8mjhoPFF8QQj+oR8qHrRh2808MBIG
+A1UdEwEB/wQIMAYBAf8CAQAwHwYDVR0jBBgwFoAUncBnpgwi2Sb1RaumZVIRJ9hF
+rGMwRwYDVR0gBEAwPjA8BgRVHSAAMDQwMgYIKwYBBQUHAgEWJmh0dHBzOi8vd3d3
+LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MEYGA1UdHwQ/MD0wO6A5oDeGNWh0
+dHA6Ly9jcmwuYWZmaXJtdHJ1c3QuY29tL2NybC9BZmZpcm1UcnVzdFByZW1pdW0u
+Y3JsMA4GA1UdDwEB/wQEAwIBhjAdBgNVHSUEFjAUBggrBgEFBQcDAQYIKwYBBQUH
+AwIwDQYJKoZIhvcNAQELBQADggIBABi64UEwl3l0yIiuSACyVQQIBI60BUmhseac
+4BzCAsJrR5tE/2U9QAa2y6JpR1nqm76DJvw1QQgvFcNe+fkwpvoViCaSTbZkGGwD
+mQe2xRSYJcDSMQUc/GgzLcX2c1CrexQXE1vwV/q33af1en5s1GzLl915aNS/k1ch
+G7EMruJ/D4cuH9j4j2i+b+llmVBzavBwelN5rc693o+Ot9id/1sTWNugwAu3uXGb
+VlhETMnjXGIciegOLdWYhWBln0izYlt9IwlDEpjMVaZ0HZlj2JBGaSe4PfEFpJPO
+beuPcQpLQGw2XpW2ZMG5JcRYaoKWjixXAGktRA3H9nvVW92jvzx/RX484w2ZM5Rt
+E+I1ikAuQLAyWG7clht387e2RuC3NZTtefSyjE3L9gQDOPC+Z9ycwr0WJHRsxFvh
+FJQi3JnxgFZf5mc5n2mh3qAgALTNOUHuDiHrerjTOWbpF/1/NJmo/c/YZ63vZIhc
+EaER4HuhbBqlpf6z3WOIQdZm1ChwXYHrEcLDgfwm9cXoaVK2HZapkMwQbPffPlT1
+E+AxRFB4YmT1y2WzdaHfhFA9nH6ByUdL5+FfrDoIIUO2e8OLOAcrJsf5+unhAhc0
+v7N48JWdmpstjkXCaCIaidrZLJxS+pikNgHB1dXF/TxokLTiPB9jcYKdGaYs3XHb
+YKLdwubu
+-----END CERTIFICATE-----
diff --git a/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumeccca-chain.pem b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumeccca-chain.pem
new file mode 100644
index 0000000000..37b1b78708
--- /dev/null
+++ b/jdk/test/sun/security/ssl/X509TrustManagerImpl/distrust/chains/entrust/affirmtrustpremiumeccca-chain.pem
@@ -0,0 +1,63 @@
+Root Certificate:
+ Version: 3 (0x2)
+ Serial Number: 8401224907861490260 (0x7497258ac73f7a54)
+ Signature Algorithm: ecdsa-with-SHA384
+ Issuer: C=US, O=AffirmTrust, CN=AffirmTrust Premium ECC
+ Validity
+ Not Before: Jan 29 14:20:24 2010 GMT
+ Not After : Dec 31 14:20:24 2040 GMT
+
+-----BEGIN CERTIFICATE-----
+MIIF0zCCBVmgAwIBAgIQFVwk9nYUM5SYOnBd+IoGtzAKBggqhkjOPQQDAzCBhTEL
+MAkGA1UEBhMCQ0ExFDASBgNVBAoTC0FmZmlybVRydXN0MSswKQYDVQQLEyJTZWUg
+d3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5MTMwMQYDVQQDEypBZmZpcm1U
+cnVzdCBFeHRlbmRlZCBWYWxpZGF0aW9uIENBIC0gRVZFQzEwHhcNMjQwNjI4MjE0
+OTUwWhcNMjUwNzI4MjE0OTQ4WjCB2DELMAkGA1UEBhMCQ0ExEDAOBgNVBAgTB09u
+dGFyaW8xDzANBgNVBAcTBk90dGF3YTETMBEGCysGAQQBgjc8AgEDEwJDQTEYMBYG
+CysGAQQBgjc8AgECEwdPbnRhcmlvMRwwGgYDVQQKExNBZmZpcm10cnVzdCBMaW1p
+dGVkMR0wGwYDVQQPExRQcml2YXRlIE9yZ2FuaXphdGlvbjEQMA4GA1UEBRMHMjU0
+MDU0NzEoMCYGA1UEAxMfdmFsaWRwcmVtaXVtZWNjLmFmZmlybXRydXN0LmNvbTB2
+MBAGByqGSM49AgEGBSuBBAAiA2IABEkLBzBYSJPRENKDaA1iBPQz+jZUV+OoM9nJ
+sr9sMfmHaqr3nlWxAMM99b9/usVfYyUxqyi+YL2Z3ZSxjX2dpyhwMtPpIQkL1pMW
+Iv55XBIcYRyl2NjcADS9B06G+nnix6OCAzcwggMzMAwGA1UdEwEB/wQCMAAwHQYD
+VR0OBBYEFP+37ywf2YJJ/4CEVy1GY4ioGm1yMB8GA1UdIwQYMBaAFMaQjAKD113j
+vjucLtVlfSoQYO7lMG4GCCsGAQUFBwEBBGIwYDAnBggrBgEFBQcwAYYbaHR0cDov
+L29jc3AuYWZmaXJtdHJ1c3QuY29tMDUGCCsGAQUFBzAChilodHRwOi8vYWlhLmFm
+ZmlybXRydXN0LmNvbS9hZnRldmVjMWNhLmNydDA+BgNVHR8ENzA1MDOgMaAvhi1o
+dHRwOi8vY3JsLmFmZmlybXRydXN0LmNvbS9jcmwvYWZ0ZXZlYzFjYS5jcmwwKgYD
+VR0RBCMwIYIfdmFsaWRwcmVtaXVtZWNjLmFmZmlybXRydXN0LmNvbTAOBgNVHQ8B
+Af8EBAMCB4AwHQYDVR0lBBYwFAYIKwYBBQUHAwEGCCsGAQUFBwMCMFYGA1UdIARP
+ME0wBwYFZ4EMAQEwQgYKKwYBBAGCjwkCBDA0MDIGCCsGAQUFBwIBFiZodHRwczov
+L3d3dy5hZmZpcm10cnVzdC5jb20vcmVwb3NpdG9yeTCCAX4GCisGAQQB1nkCBAIE
+ggFuBIIBagFoAHUA5tIxY0B3jMEQQQbXcbnOwdJA9paEhvu6hzId/R43jlAAAAGQ
+YNN5tQAABAMARjBEAiAnainEoBGI9czVh+c9QLPL30S3Rtov8zrnhlXfeKLzZQIg
+UGkntBMux0MqHt9Aj60qMsS/C4ZWF7AihVVaUKcrEVgAdgAN4fIwK9MNwUBiEgnq
+VS78R3R8sdfpMO8OQh60fk6qNAAAAZBg03m1AAAEAwBHMEUCIGI9kBByoozH4cfS
+ECW/O2N/ElkdATkt7EwQ52kcc4ICAiEA9QTh8JlJTb/ytYC1ECX0vQbrYVexg+fu
+dw7dfToF9nAAdwAS8U40vVNyTIQGGcOPP3oT+Oe1YoeInG0wBYTr5YYmOgAAAZBg
+03ndAAAEAwBIMEYCIQCox5nSCcVB2AfNYXco77zsJnYP7KAU2I4VA2GNL7I4wQIh
+AP6WEzyfBoGpYYqFmNnJUavyhKBmeNiR7eNtaFwpSc+UMAoGCCqGSM49BAMDA2gA
+MGUCMAGSNMXAAKDRk0ZOtydN95Rkja97+70TatCIIxEAsJD8Hu7lfj2LHCYFQjVY
+oaWTrQIxAKUudx7E/JnjsthuL6sNqKVHfD3iLUJyQNK9wE0SVt1xAm7Cu1JXZORE
+M64KMKoQFQ==
+-----END CERTIFICATE-----
+-----BEGIN CERTIFICATE-----
+MIIDXDCCAuKgAwIBAgIQAgKlhME0Bk3J8y0gfqNymDAKBggqhkjOPQQDAzBFMQsw
+CQYDVQQGEwJVUzEUMBIGA1UECgwLQWZmaXJtVHJ1c3QxIDAeBgNVBAMMF0FmZmly
+bVRydXN0IFByZW1pdW0gRUNDMB4XDTE5MDMyMTIwNTUwN1oXDTMwMTIwMjA0MDAw
+MFowgYUxCzAJBgNVBAYTAkNBMRQwEgYDVQQKEwtBZmZpcm1UcnVzdDErMCkGA1UE
+CxMiU2VlIHd3dy5hZmZpcm10cnVzdC5jb20vcmVwb3NpdG9yeTEzMDEGA1UEAxMq
+QWZmaXJtVHJ1c3QgRXh0ZW5kZWQgVmFsaWRhdGlvbiBDQSAtIEVWRUMxMHYwEAYH
+KoZIzj0CAQYFK4EEACIDYgAEu9f5NkumdaVlmaNaxpDB+rBk/S6lhqcUU1zTLcRz
+4G0dr4290hezjrvZJxGJ/X15aexpdD2V9cwaPD/yuEJcaaz+rg/qDoqQF3+AFqVc
+41jw1E0S59+57XVKLtXI7Xh6o4IBVDCCAVAwNwYIKwYBBQUHAQEEKzApMCcGCCsG
+AQUFBzABhhtodHRwOi8vb2NzcC5hZmZpcm10cnVzdC5jb20wHQYDVR0OBBYEFMaQ
+jAKD113jvjucLtVlfSoQYO7lMBIGA1UdEwEB/wQIMAYBAf8CAQAwHwYDVR0jBBgw
+FoAUmq8pesARNTUmUTAAw2r+QNWu1jwwRwYDVR0gBEAwPjA8BgRVHSAAMDQwMgYI
+KwYBBQUHAgEWJmh0dHBzOi8vd3d3LmFmZmlybXRydXN0LmNvbS9yZXBvc2l0b3J5
+MEkGA1UdHwRCMEAwPqA8oDqGOGh0dHA6Ly9jcmwuYWZmaXJtdHJ1c3QuY29tL2Ny
+bC9BZmZpcm1UcnVzdFByZW1pdW1FQ0MuY3JsMA4GA1UdDwEB/wQEAwIBhjAdBgNV
+HSUEFjAUBggrBgEFBQcDAQYIKwYBBQUHAwIwCgYIKoZIzj0EAwMDaAAwZQIwHJ5g
+a6sHvQ51DGr0bWq34awuwlWbybC2grHoNp5uYapcXr/qTJusb/6n+dczqFdaAjEA
+7VQY06fE9ifMnTgT9824jc3+H6kfhMk4PoIj9ouWdYfc1DyTBS/low9Hb8liQyFr
+-----END CERTIFICATE-----
diff --git a/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java b/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java
index abf576ec8d..6e3d418f97 100644
--- a/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java
+++ b/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java
@@ -1037,7 +1037,7 @@ public class TimestampCheck {
}
gencert("tsold", "-ext eku:critical=ts -startdate -40d -validity 500");
- gencert("tsbefore2019", "-ext eku:critical=ts -startdate 2018/01/01 -validity 5000");
+ gencert("tsbefore2019", "-ext eku:critical=ts -startdate 2018/01/01 -validity 3000");
gencert("tsweak", "-ext eku:critical=ts");
gencert("tsdisabled", "-ext eku:critical=ts");
diff --git a/langtools/test/tools/javac/defaultMethods/Assertions.java b/langtools/test/tools/javac/defaultMethods/Assertions.java
index 7e4649d3a5..61882baceb 100644
--- a/langtools/test/tools/javac/defaultMethods/Assertions.java
+++ b/langtools/test/tools/javac/defaultMethods/Assertions.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 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
@@ -29,7 +29,6 @@ import java.util.Set;
/*
* @test
* @bug 8025141
- * @ignore 8047675 test fails if run with assertions enabled in jtreg
* @summary Interfaces must not contain non-public fields, ensure $assertionsDisabled
* is not generated into an interface
* @compile Assertions.java
diff --git a/version.txt b/version.txt
index d4e65fa740..fbdac04019 100644
--- a/version.txt
+++ b/version.txt
@@ -1 +1 @@
-8.462.8.26.25.01-GA
\ No newline at end of file
+8.472.8.27.26.01-GA
\ No newline at end of file
|
xinxing.zxy seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.