< prev index next >

src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/XMLSecurityManager.java

Print this page
rev 52881 : 8214971: Replace use of string.equals("") with isEmpty()

@@ -526,18 +526,18 @@
      * @param sysPropertyName the name of system property
      */
     private boolean getSystemProperty(Limit limit, String sysPropertyName) {
         try {
             String value = SecuritySupport.getSystemProperty(sysPropertyName);
-            if (value != null && !value.equals("")) {
+            if (value != null && !value.isEmpty()) {
                 values[limit.ordinal()] = Integer.parseInt(value);
                 states[limit.ordinal()] = State.SYSTEMPROPERTY;
                 return true;
             }
 
             value = SecuritySupport.readJAXPProperty(sysPropertyName);
-            if (value != null && !value.equals("")) {
+            if (value != null && !value.isEmpty()) {
                 values[limit.ordinal()] = Integer.parseInt(value);
                 states[limit.ordinal()] = State.JAXPDOTPROPERTIES;
                 return true;
             }
         } catch (NumberFormatException e) {
< prev index next >