Code Review Request, JDK-8219991 : New fix of the deadlock in sun.security.ssl.SSLSocketImpl

Xuelei Fan xuelei.fan at oracle.com
Sun May 5 15:18:47 UTC 2019


All good catches!

I made the update accordingly.  Here is the new webrev:
   http://cr.openjdk.java.net/~xuelei/8219991/webrev.03/

Thanks,
Xuelei

On 5/3/2019 11:27 PM, Alan Bateman wrote:
> On 04/05/2019 02:23, Xuelei Fan wrote:
>> Hi,
>>
>> There is a surprise in the regression test.  I made the update, and 
>> now the testing passed.  Here is the new webrev:
>>     http://cr.openjdk.java.net/~xuelei/8219991/webrev.01/
> I assume you can save two volatile writes by not initializing isClosing 
> and hasDepleted to false (their initial value).
> 
> If readLockedDeplete were to throw an exception (and there several 
> opportunities for exceptions in that metho) then read would unwind 
> without unlocking. You may need to structure it to reduce that possibility.
> 
> -Alan
> 
> 



More information about the security-dev mailing list