8322782: Clean up usages of unnecessary fully qualified class name "java.util.Arrays"

Reviewed-by: alanb, aivanov
This commit is contained in:
Matthias Baesken 2024-01-04 08:06:14 +00:00
parent 4db7a1c3bb
commit 1369c545ac
9 changed files with 29 additions and 29 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 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
@ -85,7 +85,7 @@ final class DESKey implements SecretKey {
// Use the cleaner to zero the key when no longer referenced
final byte[] k = this.key;
CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}
public byte[] getEncoded() {
@ -136,7 +136,7 @@ final class DESKey implements SecretKey {
byte[] thatKey = that.getEncoded();
boolean ret = MessageDigest.isEqual(this.key, thatKey);
java.util.Arrays.fill(thatKey, (byte)0x00);
Arrays.fill(thatKey, (byte)0x00);
return ret;
} finally {
// prevent this from being cleaned for the above block
@ -168,7 +168,7 @@ final class DESKey implements SecretKey {
// Use the cleaner to zero the key when no longer referenced
final byte[] k = this.key;
CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}
/**

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 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
@ -87,7 +87,7 @@ final class DESedeKey implements SecretKey {
// Use the cleaner to zero the key when no longer referenced
final byte[] k = this.key;
CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}
public byte[] getEncoded() {
@ -137,7 +137,7 @@ final class DESedeKey implements SecretKey {
byte[] thatKey = that.getEncoded();
boolean ret = MessageDigest.isEqual(this.key, thatKey);
java.util.Arrays.fill(thatKey, (byte)0x00);
Arrays.fill(thatKey, (byte)0x00);
return ret;
} finally {
// prevent this from being cleaned for the above block
@ -162,7 +162,7 @@ final class DESedeKey implements SecretKey {
}
byte[] temp = key;
this.key = temp.clone();
java.util.Arrays.fill(temp, (byte)0x00);
Arrays.fill(temp, (byte)0x00);
DESKeyGenerator.setParityBit(key, 0);
DESKeyGenerator.setParityBit(key, 8);
@ -171,7 +171,7 @@ final class DESedeKey implements SecretKey {
// Use the cleaner to zero the key when no longer referenced
final byte[] k = this.key;
CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}
/**

View file

@ -84,7 +84,7 @@ final class PBEKey implements SecretKey {
// Use the cleaner to zero the key when no longer referenced
final byte[] k = this.key;
cleanable = CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}
public byte[] getEncoded() {
@ -196,7 +196,7 @@ final class PBEKey implements SecretKey {
// Use cleaner to zero the key when no longer referenced
final byte[] k = this.key;
cleanable = CleanerFactory.cleaner().register(this,
() -> java.util.Arrays.fill(k, (byte)0x00));
() -> Arrays.fill(k, (byte)0x00));
}