This commit is contained in:
dev
2008-02-09 13:18:22 +00:00
parent 1365d3e3b9
commit 0ed29573a7

View File

@ -555,7 +555,8 @@ public class EventPumper implements Runnable {
con.setKey(key); con.setKey(key);
try { try {
NTCPAddress naddr = con.getRemoteAddress(); NTCPAddress naddr = con.getRemoteAddress();
if (naddr.getPort() <= 0) throw new IOException("Invalid NTCP address: " + naddr); if (naddr.getPort() <= 0)
throw new IOException("Invalid NTCP address: " + naddr);
InetSocketAddress saddr = new InetSocketAddress(naddr.getHost(), naddr.getPort()); InetSocketAddress saddr = new InetSocketAddress(naddr.getHost(), naddr.getPort());
boolean connected = con.getChannel().connect(saddr); boolean connected = con.getChannel().connect(saddr);
if (connected) { if (connected) {