[ 
https://issues.apache.org/jira/browse/DERBY-4124?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12693615#action_12693615
 ] 

Ronald Tschalaer commented on DERBY-4124:
-----------------------------------------

I think you're overreacting a bit. That site is just one of many describing the 
basic issue, but if you really have problems with using information from 
webpages (in which case I presume you must not be reading any webpages at all, 
lest you get tainted by information from them) then you can also go ahead and 
do a detailed reading of JLS which, if read correctly, will also explain why 
double-checked locking is broken.

> Broken double-checked-locking in EmbeddedDataSource.findDriver
> --------------------------------------------------------------
>
>                 Key: DERBY-4124
>                 URL: https://issues.apache.org/jira/browse/DERBY-4124
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.4.2.0
>         Environment: all
>            Reporter: Ronald Tschalaer
>
> org.apache.derby.jdbc.EmbeddedDataSource.findDriver() uses the
> double-checked-locking idiom for setting the 'driver' variable. This
> idiom is, however, not correct and hence the code is broken. The fix
> is to remove the outer if, i.e. to always enter the synchronized block.
> See also
> http://www.cs.umd.edu/~pugh/java/memoryModel/DoubleCheckedLocking.html

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to