On 7/31/07, James Im <[EMAIL PROTECTED]> wrote:
<snip/>

> >>So for the case that we're talking about, I think that we agree that
> >>we've found a potential problem. The question is not then IF it will be
> >>a problem in practice or not, but rather HOW do we fix it. I believe
> >>that making the selector volatile could fix the problem. IF I am correct
> >>it should be done, unless another way to fix the problem is proposed.
> >
> >I agree with you.  Because volatile doesn't work very well in Java
> >1.4, what do we need to fix the problem in 1.0?  Would using
> >synchronized block hurt performance?
>
> Volatile works in Java 5 and 6 so that could do it for the branches
> 1.1.x and 2.0.
> For 1.4, you will need to use the lock.

I created a JIRA issue to track this problem:

http://issues.apache.org/jira/browse/DIRMINA-416

and have just checked in the fix as the following:

http://svn.apache.org/viewvc?view=rev&revision=562355

Please review my changes and let me know it's done right.

I didn't change the trunk because Selectors are final there.

Thanks,
Trustin
-- 
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP Key ID: 0x0255ECA6

Reply via email to