]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
RGW - Swift retarget needs bucket set on object 46719/head
authorDaniel Gryniewicz <dang@redhat.com>
Thu, 16 Jun 2022 15:46:24 +0000 (11:46 -0400)
committerDaniel Gryniewicz <dang@redhat.com>
Thu, 16 Jun 2022 17:12:38 +0000 (13:12 -0400)
When a bucket list is retargeted to an object get, then the object may
not yet have it's bucket set.  Ensure the bucket is set on the object.

Fixes: https://tracker.ceph.com/issues/56029
Signed-off-by: Daniel Gryniewicz <dang@redhat.com>
src/rgw/rgw_rest_swift.cc

index f7a6340a41c273f4f6caf74fd0582add9aa0b73e..93930c414fb3f84b67e1e3e9fe24d0b38a162281 100644 (file)
@@ -2474,6 +2474,7 @@ RGWOp* RGWSwiftWebsiteHandler::get_ws_index_op()
   } else {
     s->object->set_name(s->bucket->get_info().website_conf.get_index_doc());
   }
+  s->object->set_bucket(s->bucket.get());
 
   auto getop = new RGWGetObj_ObjStore_SWIFT;
   getop->set_get_data(boost::algorithm::equals("GET", s->info.method));