src/java.base/share/classes/sun/net/spi/DefaultProxySelector.java
changeset 53018 8bf9268df0e2
parent 52725 c470f977ade8
child 54116 d21803f47416
equal deleted inserted replaced
53017:e10a1f7aaa13 53018:8bf9268df0e2
   236                                  */
   236                                  */
   237                                 phost =  NetProperties.get(props[i][j]+"Host");
   237                                 phost =  NetProperties.get(props[i][j]+"Host");
   238                                 if (phost != null && phost.length() != 0)
   238                                 if (phost != null && phost.length() != 0)
   239                                     break;
   239                                     break;
   240                             }
   240                             }
   241                             if (phost == null || phost.length() == 0) {
   241                             if (phost == null || phost.isEmpty()) {
   242                                 /**
   242                                 /**
   243                                  * No system property defined for that
   243                                  * No system property defined for that
   244                                  * protocol. Let's check System Proxy
   244                                  * protocol. Let's check System Proxy
   245                                  * settings (Gnome, MacOsX & Windows) if
   245                                  * settings (Gnome, MacOsX & Windows) if
   246                                  * we were instructed to.
   246                                  * we were instructed to.
   265                                             nphosts = nprop.defaultVal;
   265                                             nphosts = nprop.defaultVal;
   266                                         } else {
   266                                         } else {
   267                                             nprop.hostsSource = null;
   267                                             nprop.hostsSource = null;
   268                                             nprop.pattern = null;
   268                                             nprop.pattern = null;
   269                                         }
   269                                         }
   270                                     } else if (nphosts.length() != 0) {
   270                                     } else if (!nphosts.isEmpty()) {
   271                                         // add the required default patterns
   271                                         // add the required default patterns
   272                                         // but only if property no set. If it
   272                                         // but only if property no set. If it
   273                                         // is empty, leave empty.
   273                                         // is empty, leave empty.
   274                                         nphosts += "|" + NonProxyInfo
   274                                         nphosts += "|" + NonProxyInfo
   275                                                          .defStringVal;
   275                                                          .defStringVal;