From 52a8984d89ee72fe4e1293cba5d395dd72c7d278 Mon Sep 17 00:00:00 2001 From: Adam Emerson Date: Fri, 10 Jan 2025 16:05:56 -0500 Subject: [PATCH] test/neorados: Silence mismatched new/delete warning This is a bug in Boost that's fixed in 1.87. Once we upgrade to that, this can be reverted. Fixes: https://tracker.ceph.com/issues/64191 Signed-off-by: Adam Emerson --- src/test/neorados/common_tests.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/test/neorados/common_tests.h b/src/test/neorados/common_tests.h index 9610f08f643f3..5c2ebde4db6aa 100644 --- a/src/test/neorados/common_tests.h +++ b/src/test/neorados/common_tests.h @@ -72,6 +72,13 @@ std::string get_temp_pool_name(std::string_view prefix = {}); /// \param token Boost.Asio completion token /// /// \return The ID of the newly created pool + +// This is a bug in Boost. It's fixed in 1.87 and these pragmata can +// be removed then. +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wmismatched-new-delete" +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wmismatched-new-delete" template CompletionToken> auto create_pool(neorados::RADOS& r, @@ -95,6 +102,8 @@ auto create_pool(neorados::RADOS& r, }, r.get_executor()), token, std::ref(r), std::move(pname)); } +#pragma GCC diagnostic pop +#pragma clang diagnostic pop /// \brief Create a new, empty RADOS object /// -- 2.39.5