Skip to content

Commit da693b1

Browse files
martinuyfranferrax
andcommitted
Sync of methods reading the properties map.
Co-authored-by: Martin Balao Alonso <[email protected]> Co-authored-by: Francisco Ferrari Bihurriet <[email protected]>
1 parent 384f2a7 commit da693b1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/java.base/share/classes/java/security/Provider.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ public synchronized Set<Map.Entry<Object,Object>> entrySet() {
429429
* @since 1.2
430430
*/
431431
@Override
432-
public Set<Object> keySet() {
432+
public synchronized Set<Object> keySet() {
433433
checkInitialized();
434434
return Collections.unmodifiableSet(super.keySet());
435435
}
@@ -441,7 +441,7 @@ public Set<Object> keySet() {
441441
* @since 1.2
442442
*/
443443
@Override
444-
public Collection<Object> values() {
444+
public synchronized Collection<Object> values() {
445445
checkInitialized();
446446
return Collections.unmodifiableCollection(super.values());
447447
}
@@ -672,7 +672,8 @@ public synchronized Enumeration<Object> elements() {
672672
}
673673

674674
// let javadoc show doc from superclass
675-
public String getProperty(String key) {
675+
@Override
676+
public synchronized String getProperty(String key) {
676677
checkInitialized();
677678
return super.getProperty(key);
678679
}

0 commit comments

Comments
 (0)