From 01df7c667ec61d5ececa4993ab0b119ee5a11334 Mon Sep 17 00:00:00 2001 From: Samuel Just Date: Thu, 9 Jun 2011 10:51:49 -0700 Subject: [PATCH] ReplicatedPG: make_writeable, use correct size for clone_size entry Previously, we used obs.oi.size for the clone size, but obs refers to new_obs. The clone's size should be the old size, ctx->obc->obs.oi.size. Signed-off-by: Samuel Just --- src/osd/ReplicatedPG.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index ac071bd7b9f9b..935f2d4c161f5 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -2104,7 +2104,7 @@ void ReplicatedPG::make_writeable(OpContext *ctx) info.stats.num_objects++; info.stats.num_object_clones++; ssc->snapset.clones.push_back(coid.snap); - ssc->snapset.clone_size[coid.snap] = obs.oi.size; + ssc->snapset.clone_size[coid.snap] = ctx->obc->obs.oi.size; // clone_overlap should contain an entry for each clone // (an empty interval_set if there is no overlap) -- 2.39.5