From: Daniel Gryniewicz Date: Mon, 7 Feb 2022 15:08:02 +0000 (-0500) Subject: RGW - Move early return X-Git-Tag: v18.0.0~1425^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F44927%2Fhead;p=ceph.git RGW - Move early return When transitioning an object to cloud, there was an early return, skipping the removal of the cloud target. Fix this to be in the right place. Signed-off-by: Daniel Gryniewicz --- diff --git a/src/rgw/rgw_lc.cc b/src/rgw/rgw_lc.cc index a819d6177780..4570689eea8e 100644 --- a/src/rgw/rgw_lc.cc +++ b/src/rgw/rgw_lc.cc @@ -1468,11 +1468,11 @@ public: if (ret < 0) { ldpp_dout(oc.dpp, 0) << "ERROR: failed to transfer object(" << oc.o.key << ") to the cloud endpoint(" << endpoint << ") ret=" << ret << dendl; - return ret; if (!tier_ctx.target_bucket_created) { cloud_targets.erase(it.first); } + return ret; } if (delete_object) {