From 5e06938bc1f37dad35a274933e00052d83387a63 Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Thu, 8 Jun 2017 12:18:42 +0800 Subject: [PATCH] client: s/atomic_t/std::atomic<> Signed-off-by: Kefu Chai --- src/client/hypertable/CephBroker.cc | 2 +- src/client/hypertable/CephBroker.h | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/client/hypertable/CephBroker.cc b/src/client/hypertable/CephBroker.cc index 77f6e083419..d7911cbfa97 100644 --- a/src/client/hypertable/CephBroker.cc +++ b/src/client/hypertable/CephBroker.cc @@ -41,7 +41,7 @@ using namespace Hypertable; -atomic_t CephBroker::ms_next_fd = ATOMIC_INIT(0); +std::atomic CephBroker::ms_next_fd{0}; /* A thread-safe version of strerror */ static std::string cpp_strerror(int err) diff --git a/src/client/hypertable/CephBroker.h b/src/client/hypertable/CephBroker.h index a0d180c4da2..d2df38909ae 100644 --- a/src/client/hypertable/CephBroker.h +++ b/src/client/hypertable/CephBroker.h @@ -27,9 +27,8 @@ extern "C" { #include } - +#include #include "Common/String.h" -#include "Common/atomic.h" #include "Common/Properties.h" #include "DfsBroker/Lib/Broker.h" @@ -97,7 +96,7 @@ namespace Hypertable { private: struct ceph_mount_info *cmount; - static atomic_t ms_next_fd; + static std::atomic ms_next_fd; virtual void report_error(ResponseCallback *cb, int error); -- 2.39.5