src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java
changeset 53018 8bf9268df0e2
parent 51733 a929ad0569ee
child 53064 103ed9569fc8
--- a/src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java	Thu Dec 13 16:14:07 2018 +0100
+++ b/src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java	Thu Dec 13 15:31:05 2018 +0100
@@ -483,7 +483,7 @@
             // default groups and preferences will be used.
             String property = GetPropertyAction
                     .privilegedGetProperty("jdk.tls.namedGroups");
-            if (property != null && property.length() != 0) {
+            if (property != null && !property.isEmpty()) {
                 // remove double quote marks from beginning/end of the property
                 if (property.length() > 1 && property.charAt(0) == '"' &&
                         property.charAt(property.length() - 1) == '"') {
@@ -492,7 +492,7 @@
             }
 
             ArrayList<NamedGroup> groupList;
-            if (property != null && property.length() != 0) {
+            if (property != null && !property.isEmpty()) {
                 String[] groups = property.split(",");
                 groupList = new ArrayList<>(groups.length);
                 for (String group : groups) {