From: myoungwon oh Date: Sun, 9 Aug 2020 11:31:02 +0000 (+0900) Subject: osd: drop the reference if redirect has the reference X-Git-Tag: v16.1.0~1248^2~12 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=7aac5a62f70bd42ca1cd66a4d49e78afd7aca146;p=ceph.git osd: drop the reference if redirect has the reference Signed-off-by: Myoungwon Oh --- diff --git a/src/osd/PrimaryLogPG.cc b/src/osd/PrimaryLogPG.cc index 90f04258ac7f..82c9c420aa68 100644 --- a/src/osd/PrimaryLogPG.cc +++ b/src/osd/PrimaryLogPG.cc @@ -3568,16 +3568,14 @@ void PrimaryLogPG::dec_all_refcount_manifest(const object_info_t& oi, OpContext* dec_refcount(soid, refs); }); } - } else if (oi.manifest.is_redirect()) { - ceph_assert(oi.flags & object_info_t::FLAG_REDIRECT_HAS_REFERENCE); + } else if (oi.manifest.is_redirect() && + oi.test_flag(object_info_t::FLAG_REDIRECT_HAS_REFERENCE)) { ctx->register_on_commit( [oi, this](){ refcount_manifest(oi.soid, oi.manifest.redirect_target, refcount_t::DECREMENT_REF, NULL); }); - } else { - ceph_abort_msg("unrecognized manifest type"); - } + } } void PrimaryLogPG::refcount_manifest(hobject_t src_soid, hobject_t tgt_soid, refcount_t type,