]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: fix overload of '==' operator for pg_stat_t
authorxie xingguo <xie.xingguo@zte.com.cn>
Mon, 29 Feb 2016 15:50:18 +0000 (23:50 +0800)
committerxie xingguo <xie.xingguo@zte.com.cn>
Mon, 29 Feb 2016 15:50:18 +0000 (23:50 +0800)
The newly added fields -- 'last_peered' and 'last_became_peered'
are not compared.

Fixes: #14921
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
src/osd/osd_types.cc

index 6f26284b69c5f2b89ea1ff5e753ec984450ef24f..8ae2a2dab2926177e8e55ffb8e3d42567913dae4 100644 (file)
@@ -2518,6 +2518,7 @@ bool operator==(const pg_stat_t& l, const pg_stat_t& r)
     l.last_fresh == r.last_fresh &&
     l.last_change == r.last_change &&
     l.last_active == r.last_active &&
+    l.last_peered == r.last_peered &&
     l.last_clean == r.last_clean &&
     l.last_unstale == r.last_unstale &&
     l.last_undegraded == r.last_undegraded &&
@@ -2542,6 +2543,7 @@ bool operator==(const pg_stat_t& l, const pg_stat_t& r)
     l.mapping_epoch == r.mapping_epoch &&
     l.blocked_by == r.blocked_by &&
     l.last_became_active == r.last_became_active &&
+    l.last_became_peered == r.last_became_peered &&
     l.dirty_stats_invalid == r.dirty_stats_invalid &&
     l.omap_stats_invalid == r.omap_stats_invalid &&
     l.hitset_stats_invalid == r.hitset_stats_invalid &&