ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/extra166y/CustomConcurrentHashMap.java
(Generate patch)

Comparing jsr166/src/extra166y/CustomConcurrentHashMap.java (file contents):
Revision 1.1 by dl, Mon Apr 6 10:30:04 2009 UTC vs.
Revision 1.2 by dl, Tue Jun 30 14:56:53 2009 UTC

# Line 1619 | Line 1619 | public class CustomConcurrentHashMap<K,
1619           * @return e, or an element equivalent to e.
1620           */
1621          public K intern(K e) {
1622 <            return cchm.doPut(e, e, true);
1622 >            K oldElement = cchm.doPut(e, e, true);
1623 >            return (oldElement != null) ? oldElement : e;
1624          }
1625          
1626          /**

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines