Should not the size.decrementAndGet() be before returning the entry
should not this...
public Object removeAndGet(KEYTYPE key){
Object[] entry = cache.remove(key);
if (entry != null) {
return entry[1];
}
size.decrementAndGet();
return null;
}
be like this...
should this
public Object removeAndGet(KEYTYPE key){
Object[] entry = cache.remove(key);
if (entry != null) {
size.decrementAndGet();
return entry[1];
}
return null;
}
Original issue reported on code.google.com by federico...@gmail.com on 17 Feb 2011 at 4:45
Original issue reported on code.google.com by
federico...@gmail.com
on 17 Feb 2011 at 4:45