]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cls/test: Make function parameters by reference not by value 67422/head
authorMatty Williams <Matty.Williams@ibm.com>
Thu, 19 Feb 2026 15:07:07 +0000 (15:07 +0000)
committerCallum James <callum.james@ibm.com>
Wed, 22 Apr 2026 14:09:13 +0000 (15:09 +0100)
Stops the cls_fifo.get_info test from Segmentation Faulting.

Fixes: https://tracker.ceph.com/issues/74648
Signed-off-by: Matty Williams <Matty.Williams@ibm.com>
src/neorados/cls/fifo.h
src/test/cls_fifo/ceph_test_neocls_fifo.cc

index 484dcd44d393661ab18f7af7915ccd5115992727..3f15a834bf664ab95a651200087cc559b5f843a1 100644 (file)
@@ -361,7 +361,7 @@ public:
   template<boost::asio::completion_token_for<
     void(boost::system::error_code, rados::cls::fifo::info,
         uint32_t, uint32_t)> CompletionToken>
-  static auto get_meta(neorados::RADOS rados, Object obj, IOContext ioc,
+  static auto get_meta(neorados::RADOS& rados, Object obj, IOContext ioc,
                       std::optional<rados::cls::fifo::objv> objv,
                       CompletionToken&& token) {
 
index 7b2020fdf1d017554598e402b14be9645fe5eeba..fd3017007796b6851a55f414c3d8dc7233df0d39 100644 (file)
@@ -46,13 +46,13 @@ namespace fifo = rados::cls::fifo;
 class FIFOtest {
 public:
   template<typename... Args>
-  static auto create_meta(neorados::RADOS rados, Args&&... args) {
+  static auto create_meta(neorados::RADOS& rados, Args&&... args) {
     return detail::FIFOImpl::create_meta(rados,
                                         std::forward<Args>(args)...);
   }
 
   template<typename... Args>
-  static auto get_meta(neorados::RADOS rados, Args&&... args) {
+  static auto get_meta(neorados::RADOS& rados, Args&&... args) {
     return FIFO::get_meta(rados, std::forward<Args>(args)...);
   }