From cdd0312e951f2fc7b71b499a6820209925ed6be6 Mon Sep 17 00:00:00 2001 From: Michael Davis <michael.davis@cern.ch> Date: Thu, 8 Nov 2018 13:34:47 +0100 Subject: [PATCH] Uses cta::make_unique instead of defining it again --- XRootdSSiRmcd/RmcdClient.cpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/XRootdSSiRmcd/RmcdClient.cpp b/XRootdSSiRmcd/RmcdClient.cpp index ed1c58beb9..be824e8967 100644 --- a/XRootdSSiRmcd/RmcdClient.cpp +++ b/XRootdSSiRmcd/RmcdClient.cpp @@ -20,6 +20,7 @@ #include <iostream> #include <iomanip> #include <algorithm> +#include <common/make_unique.hpp> #include "XrdSsiPbIStreamBuffer.hpp" #include "RmcdClient.hpp" @@ -28,14 +29,6 @@ bool is_metadata_done = false; -// note: this implementation does not disable this overload for array types - template<typename T, typename... Args> - std::unique_ptr<T> make_unique(Args&&... args) - { - return std::unique_ptr<T>(new T(std::forward<Args>(args)...)); - } - - // Define XRootD SSI callbacks namespace XrdSsiPb { @@ -222,7 +215,7 @@ RmcdClientCmd::RmcdClientCmd(int argc, char *const *const argv) : // Obtain a Service Provider std::string resource("/rmc_test"); - m_rmc_test_service_ptr = std::make_unique<XrdSsiPbServiceType>(m_endpoint, resource, config); + m_rmc_test_service_ptr = cta::make_unique<XrdSsiPbServiceType>(m_endpoint, resource, config); } void RmcdClientCmd::processMount(int argc, char *const *const argv) { -- GitLab