diff --git a/src/main/java/org/jboss/netty/channel/socket/nio/NioWorker.java b/src/main/java/org/jboss/netty/channel/socket/nio/NioWorker.java index ba257ab7ee..9ad832fb97 100644 --- a/src/main/java/org/jboss/netty/channel/socket/nio/NioWorker.java +++ b/src/main/java/org/jboss/netty/channel/socket/nio/NioWorker.java @@ -758,6 +758,7 @@ class NioWorker implements Runnable { selector, channel.getRawInterestOps(), channel); } if (future != null) { + channel.setConnected(); future.setSuccess(); } } catch (IOException e) { @@ -772,7 +773,6 @@ class NioWorker implements Runnable { } if (!server) { - channel.setConnected(); if (!((NioClientSocketChannel) channel).boundManually) { fireChannelBound(channel, localAddress); }