-
Enhancement
-
Resolution: Fixed
-
P5
-
None
-
None
-
b02
In the method java.util.jar.JarVerifier#doneWithMeta there is redundant Hashtable.containsKey call.
if (sigFileSigners.containsKey(manifestName)) {
CodeSigner[] codeSigners = sigFileSigners.remove(manifestName);
verifiedSigners.put(manifestName, codeSigners);
}
Hashtable doesn't allow null values. So, instead of pair 'containsKey'/'remove' calls, we can directly call 'remove' and then compare result with null.
if (sigFileSigners.containsKey(manifestName)) {
CodeSigner[] codeSigners = sigFileSigners.remove(manifestName);
verifiedSigners.put(manifestName, codeSigners);
}
Hashtable doesn't allow null values. So, instead of pair 'containsKey'/'remove' calls, we can directly call 'remove' and then compare result with null.