From ce6905f9e852c8fa4373002413f9bf563cd0c152 Mon Sep 17 00:00:00 2001 From: Casey Bodley Date: Fri, 8 Dec 2023 15:26:21 -0500 Subject: [PATCH] rgw/multisite: error repo coroutines store raw_obj by value RGWErrorRepoWriteCR/RGWErrorRepoRemoveCR need to copy their rgw_raw_obj arguments to extend the lifetimes until send_request() is called potential regression from https://github.com/ceph/ceph/pull/50359 Signed-off-by: Casey Bodley --- src/rgw/driver/rados/rgw_sync_error_repo.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rgw/driver/rados/rgw_sync_error_repo.cc b/src/rgw/driver/rados/rgw_sync_error_repo.cc index aca671039ee1e..c180497bd73d6 100644 --- a/src/rgw/driver/rados/rgw_sync_error_repo.cc +++ b/src/rgw/driver/rados/rgw_sync_error_repo.cc @@ -118,7 +118,7 @@ int remove(librados::ObjectWriteOperation& op, class RGWErrorRepoWriteCR : public RGWSimpleCoroutine { librados::Rados* rados; - const rgw_raw_obj& raw_obj; + rgw_raw_obj raw_obj; std::string key; ceph::real_time timestamp; @@ -163,7 +163,7 @@ RGWCoroutine* write_cr(librados::Rados* rados, class RGWErrorRepoRemoveCR : public RGWSimpleCoroutine { librados::Rados* rados; - const rgw_raw_obj& raw_obj; + rgw_raw_obj raw_obj; std::string key; ceph::real_time timestamp; -- 2.39.5