[#644] SslHandler should not defer channelActive event

- otherwise a user will have a misconception about the life cycle of the actual connection.
This commit is contained in:
Trustin Lee 2012-10-16 15:19:34 -07:00
parent 8bab0aae9e
commit 951c49f449

View File

@ -944,18 +944,12 @@ public class SslHandler
if (!future.isSuccess()) { if (!future.isSuccess()) {
ctx.pipeline().fireExceptionCaught(future.cause()); ctx.pipeline().fireExceptionCaught(future.cause());
ctx.close(); ctx.close();
} else {
// Send the event upstream after the handshake was completed without an error.
//
// See https://github.com/netty/netty/issues/358
ctx.fireChannelActive();
} }
} }
}); });
} else {
ctx.fireChannelActive();
} }
ctx.fireChannelActive();
} }
private void safeClose( private void safeClose(