]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds/CDir.cc: remove unneeded use of count 11613/head
authorMichal Jarzabek <stiopa@gmail.com>
Sun, 23 Oct 2016 10:24:14 +0000 (11:24 +0100)
committerMichal Jarzabek <stiopa@gmail.com>
Sun, 23 Oct 2016 14:00:54 +0000 (15:00 +0100)
Signed-off-by: Michal Jarzabek <stiopa@gmail.com>
src/mds/CDir.cc

index 7d101ce44b73e775cf71fb803bf4a752b16a2370..f11ff0559a2f11accfa95a7e78461acd4fa8befd 100644 (file)
@@ -3090,8 +3090,7 @@ void CDir::scrub_dentry_finished(CDentry *dn)
   dout(20) << __func__ << " on dn " << *dn << dendl;
   assert(scrub_infop && scrub_infop->directory_scrubbing);
   dentry_key_t dn_key = dn->key();
-  if (scrub_infop->directories_scrubbing.count(dn_key)) {
-    scrub_infop->directories_scrubbing.erase(dn_key);
+  if (scrub_infop->directories_scrubbing.erase(dn_key)) {
     scrub_infop->directories_scrubbed.insert(dn_key);
   } else {
     assert(scrub_infop->others_scrubbing.count(dn_key));