if(! isStarted())
return null;
Resolver r = host.find(Resolver.class);
if(r == null || ! r.isStarted())
return null;
<BUG>Socket s = getSocket();

s.connect(new InetSocketAddress(r.getInetAddress(), port), getTimeout());

return s;</BUG>
}

if(! isStarted())
return null;
SocketChannel s = getSocket();
return tryConnect(s, new InetSocketAddress(host, port));
}
public Socket createSocket(StarterNode host, int port) throws IOException {
if(! isStarted())
return null;
Resolver r = host.find(Resolver.class);
if(r == null || ! r.isStarted())
return null;
SocketChannel s = getSocket();
return tryConnect(s, new InetSocketAddress(r.getInetAddress(), port));
}
