< prev index next >

## src/com/sun/javatest/agent/SocketConnection.java

Print this page

    *** 182,192 ****
                  }
              }
          }

          private static String getHostName(InetAddress addr) {
    !         String s = (String) (addressCache.get(addr));
              if (s == null) {
                  s = addr.getHostName();
                  addressCache.put(addr, s);
              }
              return s;
    --- 182,192 ----
                  }
              }
          }

          private static String getHostName(InetAddress addr) {
    !         String s = addressCache.get(addr);
              if (s == null) {
                  s = addr.getHostName();
                  addressCache.put(addr, s);
              }
              return s;
    *** 236,242 ****
          private final OutputStream socketOutput;
          private String name;
          private boolean closed;
          private Thread waitThread;
          private static Timer timer = new Timer();
    !     private static Hashtable addressCache = new Hashtable();
      }
    --- 236,242 ----
          private final OutputStream socketOutput;
          private String name;
          private boolean closed;
          private Thread waitThread;
          private static Timer timer = new Timer();
    !     private static Hashtable<InetAddress, String> addressCache = new Hashtable<>();
      }

< prev index next >