Definitely it's a bug, but hope this code is never used. The right way
to get Selector is to ask context associated SelectorHandler.
Thank you!
WBR,
Alexey.
On Jan 18, 2010, at 11:37 , Igor Minar wrote:
> Found this odd code in 1.9.18-k:
>
> public Selector getSelector(){
> if (selector != null) {
> return selector;
> } else {
> selectorHandler.getSelector();
> }
>
> return null;
> }
>
>
> It basically means, if selector is not null return it, otherwise
> fetch it from selectorHandler but don't store it anywhere, instead
> return null.
>
> Should it be:
>
> public Selector getSelector(){
> if (selector != null) {
> return selector;
> } else {
> return selector = selectorHandler.getSelector();
> }
> }
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_grizzly.dev.java.net
> For additional commands, e-mail: dev-help_at_grizzly.dev.java.net
>