]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/pg: set dirty_info if proc_master_log() dirties info
authorxie xingguo <xie.xingguo@zte.com.cn>
Thu, 24 Mar 2016 08:17:57 +0000 (16:17 +0800)
committerxie xingguo <xie.xingguo@zte.com.cn>
Thu, 24 Mar 2016 08:27:16 +0000 (16:27 +0800)
There are newly added branches for proc_master_log() method will
potentially dirty info but without setting dirty_info flag.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
src/osd/PG.cc

index 15dc0af1d913ce3cfea4021f74eb918f6a530490..76cd700c1b3b6f39f59d17b41345303fa6896ef7 100644 (file)
@@ -303,9 +303,12 @@ void PG::proc_master_log(
   might_have_unfound.insert(from);
 
   // See doc/dev/osd_internals/last_epoch_started
-  if (oinfo.last_epoch_started > info.last_epoch_started)
+  if (oinfo.last_epoch_started > info.last_epoch_started) {
     info.last_epoch_started = oinfo.last_epoch_started;
-  info.history.merge(oinfo.history);
+    dirty_info = true;
+  }
+  if (info.history.merge(oinfo.history))
+    dirty_info = true;
   assert(cct->_conf->osd_find_best_info_ignore_history_les ||
         info.last_epoch_started >= info.history.last_epoch_started);