Skip to content

Commit 24863d7

Browse files
authored
Merge branch 'master' into goetz_backport_8358532
2 parents 35e0b71 + 771f277 commit 24863d7

File tree

37 files changed

+827
-188
lines changed

37 files changed

+827
-188
lines changed

src/hotspot/share/utilities/vmError.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,12 +107,13 @@ const intptr_t VMError::segfault_address = pd_segfault_address;
107107
static const char* env_list[] = {
108108
// All platforms
109109
"JAVA_HOME", "JAVA_TOOL_OPTIONS", "_JAVA_OPTIONS", "CLASSPATH",
110-
"PATH", "USERNAME",
110+
"JDK_AOT_VM_OPTIONS",
111+
"JAVA_OPTS", "PATH", "USERNAME",
111112

112113
"XDG_CACHE_HOME", "XDG_CONFIG_HOME", "FC_LANG", "FONTCONFIG_USE_MMAP",
113114

114115
// Env variables that are defined on Linux/BSD
115-
"LD_LIBRARY_PATH", "LD_PRELOAD", "SHELL", "DISPLAY",
116+
"LD_LIBRARY_PATH", "LD_PRELOAD", "SHELL", "DISPLAY", "WAYLAND_DISPLAY",
116117
"HOSTTYPE", "OSTYPE", "ARCH", "MACHTYPE",
117118
"LANG", "LC_ALL", "LC_CTYPE", "LC_NUMERIC", "LC_TIME",
118119
"TERM", "TMPDIR", "TZ",

src/java.desktop/share/classes/javax/swing/plaf/basic/BasicPasswordFieldUI.java

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -91,23 +91,4 @@ protected void installDefaults() {
9191
public View create(Element elem) {
9292
return new PasswordView(elem);
9393
}
94-
95-
/**
96-
* Create the action map for Password Field. This map provides
97-
* same actions for double mouse click and
98-
* and for triple mouse click (see bug 4231444).
99-
*/
100-
101-
ActionMap createActionMap() {
102-
ActionMap map = super.createActionMap();
103-
if (map.get(DefaultEditorKit.selectWordAction) != null) {
104-
Action a = map.get(DefaultEditorKit.selectLineAction);
105-
if (a != null) {
106-
map.remove(DefaultEditorKit.selectWordAction);
107-
map.put(DefaultEditorKit.selectWordAction, a);
108-
}
109-
}
110-
return map;
111-
}
112-
11394
}

src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2022, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -647,6 +647,22 @@ ActionMap createActionMap() {
647647
TransferHandler.getCopyAction());
648648
map.put(TransferHandler.getPasteAction().getValue(Action.NAME),
649649
TransferHandler.getPasteAction());
650+
651+
if (getComponent() instanceof JPasswordField) {
652+
// Edit the action map for Password Field. This map provides
653+
// same actions for double mouse click and
654+
// and for triple mouse click (see bugs 4231444, 8354646).
655+
656+
if (map.get(DefaultEditorKit.selectWordAction) != null) {
657+
map.remove(DefaultEditorKit.selectWordAction);
658+
659+
Action a = map.get(DefaultEditorKit.selectLineAction);
660+
if (a != null) {
661+
map.put(DefaultEditorKit.selectWordAction, a);
662+
}
663+
}
664+
}
665+
650666
return map;
651667
}
652668

src/java.desktop/share/classes/javax/swing/plaf/synth/SynthPasswordFieldUI.java

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2002, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -108,19 +108,4 @@ public void paintBorder(SynthContext context, Graphics g, int x,
108108
int y, int w, int h) {
109109
context.getPainter().paintPasswordFieldBorder(context, g, x, y, w, h);
110110
}
111-
112-
/**
113-
* {@inheritDoc}
114-
*/
115-
@Override
116-
protected void installKeyboardActions() {
117-
super.installKeyboardActions();
118-
ActionMap map = SwingUtilities.getUIActionMap(getComponent());
119-
if (map != null && map.get(DefaultEditorKit.selectWordAction) != null) {
120-
Action a = map.get(DefaultEditorKit.selectLineAction);
121-
if (a != null) {
122-
map.put(DefaultEditorKit.selectWordAction, a);
123-
}
124-
}
125-
}
126111
}

src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeAnnotations.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1018,7 +1018,11 @@ private Attribute.TypeCompound toTypeCompound(Attribute.Compound a, TypeAnnotati
10181018
if (!invocation.typeargs.contains(tree)) {
10191019
return TypeAnnotationPosition.unknown;
10201020
}
1021-
MethodSymbol exsym = (MethodSymbol) TreeInfo.symbol(invocation.getMethodSelect());
1021+
Symbol exsym = TreeInfo.symbol(invocation.getMethodSelect());
1022+
if (exsym.type.isErroneous()) {
1023+
// bail out, don't deal with erroneous types which would be reported anyways
1024+
return TypeAnnotationPosition.unknown;
1025+
}
10221026
final int type_index = invocation.typeargs.indexOf(tree);
10231027
if (exsym == null) {
10241028
throw new AssertionError("could not determine symbol for {" + invocation + "}");

src/jdk.crypto.cryptoki/share/native/libj2pkcs11/p11_convert.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1317,8 +1317,7 @@ jobject ckAttributeValueToJObject(JNIEnv *env, const CK_ATTRIBUTE_PTR ckpAttribu
13171317
case CKA_OWNER:
13181318
case CKA_AC_ISSUER:
13191319
case CKA_ATTR_TYPES:
1320-
case CKA_ECDSA_PARAMS:
1321-
/* CKA_EC_PARAMS is the same, these two are equivalent */
1320+
case CKA_EC_PARAMS:
13221321
case CKA_EC_POINT:
13231322
case CKA_PRIVATE_EXPONENT:
13241323
case CKA_PRIME_1:

src/jdk.crypto.cryptoki/share/native/libj2pkcs11/p11_keymgmt.c

Lines changed: 56 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2003, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
33
*/
44

55
/* Copyright (c) 2002 Graz University of Technology. All rights reserved.
@@ -56,69 +56,78 @@
5656

5757
#ifdef P11_ENABLE_GETNATIVEKEYINFO
5858

59-
#define CK_ATTRIBUTES_TEMPLATE_LENGTH (CK_ULONG)61U
59+
#define CK_ATTRIBUTES_TEMPLATE_LENGTH (CK_ULONG)60U
6060

61+
// Group attributes based on their value types; put attributes whose values
62+
// requiring address alignments, e.g. CK_ULONG, first
6163
static CK_ATTRIBUTE ckpAttributesTemplate[CK_ATTRIBUTES_TEMPLATE_LENGTH] = {
62-
{CKA_CLASS, 0, 0},
63-
{CKA_TOKEN, 0, 0},
64-
{CKA_PRIVATE, 0, 0},
65-
{CKA_LABEL, 0, 0},
66-
{CKA_APPLICATION, 0, 0},
67-
{CKA_VALUE, 0, 0},
68-
{CKA_OBJECT_ID, 0, 0},
64+
// CK_ULONG
6965
{CKA_CERTIFICATE_TYPE, 0, 0},
70-
{CKA_ISSUER, 0, 0},
71-
{CKA_SERIAL_NUMBER, 0, 0},
72-
{CKA_AC_ISSUER, 0, 0},
73-
{CKA_OWNER, 0, 0},
74-
{CKA_ATTR_TYPES, 0, 0},
75-
{CKA_TRUSTED, 0, 0},
66+
{CKA_CLASS, 0, 0},
67+
{CKA_HW_FEATURE_TYPE, 0, 0},
68+
{CKA_KEY_GEN_MECHANISM, 0, 0},
7669
{CKA_KEY_TYPE, 0, 0},
77-
{CKA_SUBJECT, 0, 0},
78-
{CKA_ID, 0, 0},
79-
{CKA_SENSITIVE, 0, 0},
80-
{CKA_ENCRYPT, 0, 0},
81-
{CKA_DECRYPT, 0, 0},
82-
{CKA_WRAP, 0, 0},
83-
{CKA_UNWRAP, 0, 0},
84-
{CKA_SIGN, 0, 0},
85-
{CKA_SIGN_RECOVER, 0, 0},
86-
{CKA_VERIFY, 0, 0},
87-
{CKA_VERIFY_RECOVER, 0, 0},
88-
{CKA_DERIVE, 0, 0},
89-
{CKA_START_DATE, 0, 0},
90-
{CKA_END_DATE, 0, 0},
91-
{CKA_MODULUS, 0, 0},
9270
{CKA_MODULUS_BITS, 0, 0},
93-
{CKA_PUBLIC_EXPONENT, 0, 0},
94-
{CKA_PRIVATE_EXPONENT, 0, 0},
95-
{CKA_PRIME_1, 0, 0},
96-
{CKA_PRIME_2, 0, 0},
97-
{CKA_EXPONENT_1, 0, 0},
98-
{CKA_EXPONENT_2, 0, 0},
99-
{CKA_COEFFICIENT, 0, 0},
100-
{CKA_PRIME, 0, 0},
101-
{CKA_SUBPRIME, 0, 0},
102-
{CKA_BASE, 0, 0},
10371
{CKA_PRIME_BITS, 0, 0},
10472
{CKA_SUB_PRIME_BITS, 0, 0},
10573
{CKA_VALUE_BITS, 0, 0},
10674
{CKA_VALUE_LEN, 0, 0},
75+
// CK_BBOOL
76+
{CKA_ALWAYS_SENSITIVE, 0, 0},
77+
{CKA_DECRYPT, 0, 0},
78+
{CKA_DERIVE, 0, 0},
79+
{CKA_ENCRYPT, 0, 0},
10780
{CKA_EXTRACTABLE, 0, 0},
81+
{CKA_HAS_RESET, 0, 0},
10882
{CKA_LOCAL, 0, 0},
109-
{CKA_NEVER_EXTRACTABLE, 0, 0},
110-
{CKA_ALWAYS_SENSITIVE, 0, 0},
111-
{CKA_KEY_GEN_MECHANISM, 0, 0},
11283
{CKA_MODIFIABLE, 0, 0},
113-
{CKA_ECDSA_PARAMS, 0, 0},
84+
{CKA_NEVER_EXTRACTABLE, 0, 0},
85+
{CKA_PRIVATE, 0, 0},
86+
{CKA_RESET_ON_INIT, 0, 0},
87+
{CKA_SENSITIVE, 0, 0},
88+
{CKA_SIGN, 0, 0},
89+
{CKA_SIGN_RECOVER, 0, 0},
90+
{CKA_TOKEN, 0, 0},
91+
{CKA_TRUSTED, 0, 0},
92+
{CKA_UNWRAP, 0, 0},
93+
{CKA_VERIFY, 0, 0},
94+
{CKA_VERIFY_RECOVER, 0, 0},
95+
{CKA_WRAP, 0, 0},
96+
// PTR: byte[]
97+
{CKA_AC_ISSUER, 0, 0},
98+
{CKA_ATTR_TYPES, 0, 0},
99+
{CKA_BASE, 0, 0},
100+
{CKA_COEFFICIENT, 0, 0},
114101
{CKA_EC_PARAMS, 0, 0},
115102
{CKA_EC_POINT, 0, 0},
103+
{CKA_EXPONENT_1, 0, 0},
104+
{CKA_EXPONENT_2, 0, 0},
105+
{CKA_ID, 0, 0},
106+
{CKA_ISSUER, 0, 0},
107+
{CKA_MODULUS, 0, 0},
108+
{CKA_OBJECT_ID, 0, 0},
109+
{CKA_OWNER, 0, 0},
110+
{CKA_PRIME, 0, 0},
111+
{CKA_PRIME_1, 0, 0},
112+
{CKA_PRIME_2, 0, 0},
113+
{CKA_PRIVATE_EXPONENT, 0, 0},
114+
{CKA_PUBLIC_EXPONENT, 0, 0},
115+
{CKA_SERIAL_NUMBER, 0, 0},
116+
{CKA_SUBJECT, 0, 0},
117+
{CKA_SUBPRIME, 0, 0},
118+
{CKA_VALUE, 0, 0},
119+
// PTR: CK_UTF8CHAR[]
120+
{CKA_APPLICATION, 0, 0},
121+
{CKA_LABEL, 0, 0},
122+
// PTR: CK_DATE
123+
{CKA_START_DATE, 0, 0},
124+
{CKA_END_DATE, 0, 0},
125+
// deprecated
116126
{CKA_SECONDARY_AUTH, 0, 0},
117127
{CKA_AUTH_PIN_FLAGS, 0, 0},
118-
{CKA_HW_FEATURE_TYPE, 0, 0},
119-
{CKA_RESET_ON_INIT, 0, 0},
120-
{CKA_HAS_RESET, 0, 0},
128+
// misc
121129
{CKA_VENDOR_DEFINED, 0, 0},
130+
// keep this at the end to match the impl in getNativeKeyInfo(...)
122131
{CKA_NETSCAPE_DB, 0, 0},
123132
};
124133

test/hotspot/jtreg/compiler/lib/compile_framework/Compile.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2024, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -39,6 +39,7 @@
3939
*/
4040
class Compile {
4141
private static final int COMPILE_TIMEOUT = 60;
42+
private static final float timeoutFactor = Float.parseFloat(System.getProperty("test.timeout.factor", "1.0"));
4243

4344
private static final String JAVA_PATH = JDKToolFinder.getJDKTool("java");
4445
private static final String JAVAC_PATH = JDKToolFinder.getJDKTool("javac");
@@ -178,7 +179,8 @@ private static void executeCompileCommand(List<String> command) {
178179
int exitCode;
179180
try {
180181
Process process = builder.start();
181-
boolean exited = process.waitFor(COMPILE_TIMEOUT, TimeUnit.SECONDS);
182+
long timeout = COMPILE_TIMEOUT * (long)timeoutFactor;
183+
boolean exited = process.waitFor(timeout, TimeUnit.SECONDS);
182184
if (!exited) {
183185
process.destroyForcibly();
184186
System.out.println("Timeout: compile command: " + String.join(" ", command));

test/hotspot/jtreg/gc/g1/plab/TestPLABEvacuationFailure.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,6 @@ private static void runTest(int wastePct, int plabSize, int parGCThreads, int he
9999
// Set up test GC and PLAB options
100100
List<String> testOptions = new ArrayList<>();
101101
Collections.addAll(testOptions, COMMON_OPTIONS);
102-
Collections.addAll(testOptions, Utils.getTestJavaOpts());
103102
Collections.addAll(testOptions,
104103
"-XX:ParallelGCThreads=" + parGCThreads,
105104
"-XX:ParallelGCBufferWastePct=" + wastePct,

test/hotspot/jtreg/gc/g1/plab/lib/PLABUtils.java

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -73,14 +73,12 @@ public static List<String> prepareOptions(List<String> options) {
7373
if (options == null) {
7474
throw new IllegalArgumentException("Options cannot be null");
7575
}
76-
List<String> executionOtions = new ArrayList<>(
77-
Arrays.asList(Utils.getTestJavaOpts())
78-
);
79-
Collections.addAll(executionOtions, WB_DIAGNOSTIC_OPTIONS);
80-
Collections.addAll(executionOtions, G1_PLAB_LOGGING_OPTIONS);
81-
Collections.addAll(executionOtions, GC_TUNE_OPTIONS);
82-
executionOtions.addAll(options);
83-
return executionOtions;
76+
List<String> executionOptions = new ArrayList<>();
77+
Collections.addAll(executionOptions, WB_DIAGNOSTIC_OPTIONS);
78+
Collections.addAll(executionOptions, G1_PLAB_LOGGING_OPTIONS);
79+
Collections.addAll(executionOptions, GC_TUNE_OPTIONS);
80+
executionOptions.addAll(options);
81+
return executionOptions;
8482
}
8583

8684
/**

0 commit comments

Comments
 (0)