aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/surface
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-04-11 10:46:31 -0700
committerGravatar Craig Tiller <ctiller@google.com>2017-04-11 10:46:31 -0700
commit85db77951c29c3441cf37bf32980b6185a2d14d2 (patch)
tree673696887616b4a0c0517201f8fb5bd748c2f736 /src/core/lib/surface
parent2d111bd2f994c771f8a260cffee9e1c49dc99931 (diff)
Work around atomics
Diffstat (limited to 'src/core/lib/surface')
-rw-r--r--src/core/lib/surface/lame_client.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/core/lib/surface/lame_client.cc b/src/core/lib/surface/lame_client.cc
index 4616fc5830..7a64726edb 100644
--- a/src/core/lib/surface/lame_client.cc
+++ b/src/core/lib/surface/lame_client.cc
@@ -39,6 +39,8 @@
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
+#include "src/core/lib/support/atomic.h"
+
extern "C" {
#include "src/core/lib/channel/channel_stack.h"
#include "src/core/lib/support/string.h"
@@ -56,7 +58,7 @@ namespace {
struct CallData {
grpc_linked_mdelem status;
grpc_linked_mdelem details;
- std::atomic<bool> filled_metadata;
+ grpc_core::atomic<bool> filled_metadata;
};
struct ChannelData {
@@ -69,8 +71,8 @@ static void fill_metadata(grpc_exec_ctx *exec_ctx, grpc_call_element *elem,
CallData *calld = static_cast<CallData *>(elem->call_data);
bool expected = false;
if (!calld->filled_metadata.compare_exchange_strong(
- expected, true, std::memory_order_relaxed,
- std::memory_order_relaxed)) {
+ expected, true, grpc_core::memory_order_relaxed,
+ grpc_core::memory_order_relaxed)) {
return;
}
ChannelData *chand = static_cast<ChannelData *>(elem->channel_data);