db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@apache.org>
Subject Re: [jira] Updated: (DERBY-700) Derby does not prevent dual boot of database from different classloaders on Linux
Date Wed, 30 May 2007 18:43:07 GMT
Mike Matrigali wrote:
> 
> 
> Kathey Marsden (JIRA) wrote:
>>      [ 
>> https://issues.apache.org/jira/browse/DERBY-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

>> ]
>>
>> Kathey Marsden updated DERBY-700:
>> ---------------------------------
>>
>>     Attachment: derby-700_with_NPE_fix_diff.txt
> If string.intern()sync does not work then following comment does not 
> matter.
> 
> It looks like code does synchronized(DERBY_JVM_ID) but I think it wants 
> to do synchronized on intern of that string.

Actually string constants are by definition interned, so 
synchronized(DERBY_JVM_ID) is the same as 
synchronized(DERBY_JVM_ID.intern()) since DERBY_JVM_ID is a reference to 
a string constant. Though using intern() wouldn't harm and might make 
the code more readable.

Dan.



Mime
View raw message