mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
Merge
This commit is contained in:
commit
def1ac3acc
200 changed files with 1089 additions and 616 deletions
|
@ -341,7 +341,7 @@ public class Cipher {
|
|||
throw new NoSuchAlgorithmException("Invalid transformation " +
|
||||
"format:" + transformation);
|
||||
}
|
||||
if ((parts[0] == null) || (parts[0].length() == 0)) {
|
||||
if ((parts[0] == null) || (parts[0].isEmpty())) {
|
||||
throw new NoSuchAlgorithmException("Invalid transformation:" +
|
||||
"algorithm not specified-"
|
||||
+ transformation);
|
||||
|
@ -445,10 +445,10 @@ public class Cipher {
|
|||
String alg = parts[0];
|
||||
String mode = parts[1];
|
||||
String pad = parts[2];
|
||||
if ((mode != null) && (mode.length() == 0)) {
|
||||
if ((mode != null) && (mode.isEmpty())) {
|
||||
mode = null;
|
||||
}
|
||||
if ((pad != null) && (pad.length() == 0)) {
|
||||
if ((pad != null) && (pad.isEmpty())) {
|
||||
pad = null;
|
||||
}
|
||||
|
||||
|
@ -634,7 +634,7 @@ public class Cipher {
|
|||
if ((transformation == null) || transformation.isEmpty()) {
|
||||
throw new NoSuchAlgorithmException("Null or empty transformation");
|
||||
}
|
||||
if ((provider == null) || (provider.length() == 0)) {
|
||||
if ((provider == null) || (provider.isEmpty())) {
|
||||
throw new IllegalArgumentException("Missing provider");
|
||||
}
|
||||
Provider p = Security.getProvider(provider);
|
||||
|
|
|
@ -337,7 +337,7 @@ public class SealedObject implements Serializable {
|
|||
if (key == null) {
|
||||
throw new NullPointerException("key is null");
|
||||
}
|
||||
if (provider == null || provider.length() == 0) {
|
||||
if (provider == null || provider.isEmpty()) {
|
||||
throw new IllegalArgumentException("missing provider");
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue