ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/main/java/util/concurrent/ConcurrentHashMap.java
(Generate patch)

Comparing jsr166/src/main/java/util/concurrent/ConcurrentHashMap.java (file contents):
Revision 1.252 by dl, Sun Dec 1 13:38:58 2013 UTC vs.
Revision 1.253 by dl, Sun Dec 1 16:08:09 2013 UTC

# Line 2809 | Line 2809 | public class ConcurrentHashMap<K,V> exte
2809           */
2810          final Node<K,V> find(int h, Object k) {
2811              if (k != null) {
2812 <                for (Node<K,V> e = first; e != null; e = e.next) {
2812 >                for (Node<K,V> e = first; e != null; ) {
2813                      int s; K ek;
2814                      if (((s = lockState) & (WAITER|WRITER)) != 0) {
2815                          if (e.hash == h &&
2816                              ((ek = e.key) == k || (ek != null && k.equals(ek))))
2817                              return e;
2818 +                        e = e.next;
2819                      }
2820                      else if (U.compareAndSwapInt(this, LOCKSTATE, s,
2821                                                   s + READER)) {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines