SecurityManager s = System.getSecurityManager();
  public InetAddress getLocalAddress()  {    SecurityManager s = System.getSecurityManager();    // FIXME: JCL p. 510 says this should call checkConnect.  But what    // string should be used as the hostname?  Maybe this is just a side    // effect of calling InetAddress.getLocalHost.    //    // And is getOption with SO_BINDADDR the right way to get the address?    // Doesn't seem to be since this method doesn't throw a SocketException    // and SO_BINADDR can throw one.    //    // Also see RETURNS section in JCL p. 510 about returning any local    // addr "if the current execution context is not allowed to connect to    // the network interface that is actually bound to this datagram socket."    // How is that done?  via InetAddress.getLocalHost?  But that throws    // an UnknownHostException and this method doesn't.    //    // if (s != null)    //   s.checkConnect("localhost", -1);    try      {	return (InetAddress)impl.getOption(SocketOptions.SO_BINDADDR);      }    catch (SocketException ex)      {      }    try      {	return InetAddress.getLocalHost();      }    catch (UnknownHostException ex)      {	// FIXME: This should never happen, so how can we avoid this construct?	return null;      }  }