< prev index next >

src/java.rmi/share/classes/sun/rmi/transport/tcp/TCPEndpoint.java

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

@@ -736,11 +736,11 @@
                     /* propagate the exception to the caller */
                     Thread.currentThread().interrupt();
                 }
                 hostName = f.getHost();
 
-                if ((hostName == null) || (hostName.equals(""))
+                if ((hostName == null) || (hostName.isEmpty())
                     || (hostName.indexOf('.') < 0 )) {
 
                     hostName = hostAddress;
                 }
             }
< prev index next >