Fixed folly::AtomicHashMap::iterator not advancing past empty submaps
authorMike Kolupaev <kolmike@fb.com>
Fri, 19 Dec 2014 20:17:41 +0000 (12:17 -0800)
committerDave Watson <davejwatson@fb.com>
Mon, 29 Dec 2014 18:39:50 +0000 (10:39 -0800)
commitd8d3e2676a073e415ecbfeb3144948ddcd6449df
treedce8dbd613de7999df8470b8e666a12b3d3f9abf
parent0b028d4ae1effbaf275b99d6bf0608429d9d4434
Fixed folly::AtomicHashMap::iterator not advancing past empty submaps

Summary: A potential "real life" scenario that maybe can hit this bug is if we erase almost all elements and then iterate over the whole map.

Test Plan: Added a test for it.

Reviewed By: mwilliams@fb.com

Subscribers: folly-diffs@, lovro

FB internal diff: D1751455

Tasks: 5866368

Signature: t1:1751455:1419016611:b44c41d348f54397844460cb38002ad0d9704972
folly/AtomicHashMap-inl.h
folly/test/AtomicHashMapTest.cpp